diff options
Diffstat (limited to 'src/include/commands/explain.h')
-rw-r--r-- | src/include/commands/explain.h | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/src/include/commands/explain.h b/src/include/commands/explain.h index a5cc40367f8..fa2c8aac668 100644 --- a/src/include/commands/explain.h +++ b/src/include/commands/explain.h @@ -6,7 +6,7 @@ * Portions Copyright (c) 1996-2009, PostgreSQL Global Development Group * Portions Copyright (c) 1994-5, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/commands/explain.h,v 1.40 2009/07/26 23:34:18 tgl Exp $ + * $PostgreSQL: pgsql/src/include/commands/explain.h,v 1.41 2009/08/10 05:46:50 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -15,16 +15,26 @@ #include "executor/executor.h" +typedef enum ExplainFormat +{ + EXPLAIN_FORMAT_TEXT, + EXPLAIN_FORMAT_XML, + EXPLAIN_FORMAT_JSON +} ExplainFormat; + typedef struct ExplainState { StringInfo str; /* output buffer */ /* options */ - bool verbose; /* print plan targetlists */ + bool verbose; /* be verbose */ bool analyze; /* print actual times */ bool costs; /* print costs */ + ExplainFormat format; /* output format */ /* other states */ PlannedStmt *pstmt; /* top of plan */ List *rtable; /* range table */ + int indent; /* current indentation level */ + List *grouping_stack; /* format-specific grouping state */ } ExplainState; /* Hook for plugins to get control in ExplainOneQuery() */ @@ -54,4 +64,6 @@ extern void ExplainOnePlan(PlannedStmt *plannedstmt, ExplainState *es, extern void ExplainPrintPlan(ExplainState *es, QueryDesc *queryDesc); +extern void ExplainSeparatePlans(ExplainState *es); + #endif /* EXPLAIN_H */ |