diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2008-08-19 18:30:04 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2008-08-19 18:30:04 +0000 |
commit | 9650830bc82045b32573e52b0843d6a2f56b802a (patch) | |
tree | 9afe0c48788939c9c6a43efac2ccb91dfe79aa3b /src/backend/tcop/postgres.c | |
parent | 2aaca8e3143e10e1514fceb6654987a1f6b3f4ca (diff) | |
download | postgresql-9650830bc82045b32573e52b0843d6a2f56b802a.tar.gz postgresql-9650830bc82045b32573e52b0843d6a2f56b802a.zip |
Cause the output from debug_print_parse, debug_print_rewritten, and
debug_print_plan to appear at LOG message level, not DEBUG1 as historically.
Make debug_pretty_print default to on. Also, cause plans generated via
EXPLAIN to be subject to debug_print_plan. This is all to make
debug_print_plan a reasonably comfortable substitute for the former behavior
of EXPLAIN VERBOSE.
Diffstat (limited to 'src/backend/tcop/postgres.c')
-rw-r--r-- | src/backend/tcop/postgres.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/backend/tcop/postgres.c b/src/backend/tcop/postgres.c index 132d33c5a9d..8449cb4d4c1 100644 --- a/src/backend/tcop/postgres.c +++ b/src/backend/tcop/postgres.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/tcop/postgres.c,v 1.555 2008/08/01 13:16:09 alvherre Exp $ + * $PostgreSQL: pgsql/src/backend/tcop/postgres.c,v 1.556 2008/08/19 18:30:04 tgl Exp $ * * NOTES * this is the "main" module of the postgres backend and @@ -630,13 +630,13 @@ pg_rewrite_query(Query *query) { List *querytree_list; - if (log_parser_stats) - ResetUsage(); - if (Debug_print_parse) - elog_node_display(DEBUG1, "parse tree", query, + elog_node_display(LOG, "parse tree", query, Debug_pretty_print); + if (log_parser_stats) + ResetUsage(); + if (query->commandType == CMD_UTILITY) { /* don't rewrite utilities, just dump 'em into result list */ @@ -666,7 +666,7 @@ pg_rewrite_query(Query *query) #endif if (Debug_print_rewritten) - elog_node_display(DEBUG1, "rewritten parse tree", querytree_list, + elog_node_display(LOG, "rewritten parse tree", querytree_list, Debug_pretty_print); return querytree_list; @@ -720,7 +720,7 @@ pg_plan_query(Query *querytree, int cursorOptions, ParamListInfo boundParams) * Print plan if debugging. */ if (Debug_print_plan) - elog_node_display(DEBUG1, "plan", plan, Debug_pretty_print); + elog_node_display(LOG, "plan", plan, Debug_pretty_print); TRACE_POSTGRESQL_QUERY_PLAN_DONE(); |