From 182bf40c344721162291fdb2ea8b7bedd130517f Mon Sep 17 00:00:00 2001 From: Artem Gavrilov Date: Fri, 5 Sep 2025 16:49:52 +0200 Subject: [PATCH] PG-1907 Fix explain imports for PG18 explain.h header file was splitted in PostgreSQL 18, so import required headers for that version. --- pg_stat_monitor.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pg_stat_monitor.c b/pg_stat_monitor.c index 4401d77..2db8eb8 100644 --- a/pg_stat_monitor.c +++ b/pg_stat_monitor.c @@ -21,6 +21,12 @@ #include "utils/guc.h" #include "pgstat.h" #include "commands/dbcommands.h" + +#if PG_VERSION_NUM >= 180000 +#include "commands/explain_state.h" +#include "commands/explain_format.h" +#endif + #include "commands/explain.h" #include "pg_stat_monitor.h"