mirror of
https://github.com/postgres/postgres.git
synced 2025-07-15 19:21:59 +03:00
Change EXPLAIN output so that subplans and initplans (particularly CTEs)
are individually labeled, rather than just grouped under an "InitPlan" or "SubPlan" heading. This in turn makes it possible for decompilation of a subplan reference to usefully identify which subplan it's referencing. I also made InitPlans identify which parameter symbol(s) they compute, so that references to those parameters elsewhere in the plan tree can be connected to the initplan that will be executed. Per a gripe from Robert Haas about EXPLAIN output of a WITH query being inadequate, plus some longstanding pet peeves of my own.
This commit is contained in:
@ -8,7 +8,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $PostgreSQL: pgsql/src/backend/nodes/outfuncs.c,v 1.357 2009/04/04 21:12:31 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/backend/nodes/outfuncs.c,v 1.358 2009/04/05 19:59:40 tgl Exp $
|
||||
*
|
||||
* NOTES
|
||||
* Every node type that can appear in stored rules' parsetrees *must*
|
||||
@ -961,6 +961,7 @@ _outSubPlan(StringInfo str, SubPlan *node)
|
||||
WRITE_NODE_FIELD(testexpr);
|
||||
WRITE_NODE_FIELD(paramIds);
|
||||
WRITE_INT_FIELD(plan_id);
|
||||
WRITE_STRING_FIELD(plan_name);
|
||||
WRITE_OID_FIELD(firstColType);
|
||||
WRITE_INT_FIELD(firstColTypmod);
|
||||
WRITE_BOOL_FIELD(useHashTable);
|
||||
|
Reference in New Issue
Block a user