aboutsummaryrefslogtreecommitdiff
path: root/src/backend/commands/explain.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2005-04-22 21:58:32 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2005-04-22 21:58:32 +0000
commitbc843d396032acb75abfbcfab1a0c3b0b252c3f1 (patch)
tree1c5f8401d96790fc45c810f7e19eba1c1d61ba79 /src/backend/commands/explain.c
parentccbb07d92229a3ebdfbb129aafaba99a22658403 (diff)
downloadpostgresql-bc843d396032acb75abfbcfab1a0c3b0b252c3f1.tar.gz
postgresql-bc843d396032acb75abfbcfab1a0c3b0b252c3f1.zip
First cut at planner support for bitmap index scans. Lots to do yet,
but the code is basically working. Along the way, rewrite the entire approach to processing OR index conditions, and make it work in join cases for the first time ever. orindxpath.c is now basically obsolete, but I left it in for the time being to allow easy comparison testing against the old implementation.
Diffstat (limited to 'src/backend/commands/explain.c')
-rw-r--r--src/backend/commands/explain.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/src/backend/commands/explain.c b/src/backend/commands/explain.c
index e26406365de..7e8d2db677b 100644
--- a/src/backend/commands/explain.c
+++ b/src/backend/commands/explain.c
@@ -7,7 +7,7 @@
* Portions Copyright (c) 1994-5, Regents of the University of California
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/backend/commands/explain.c,v 1.133 2005/04/19 22:35:10 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/commands/explain.c,v 1.134 2005/04/22 21:58:31 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -847,9 +847,14 @@ explain_outNode(StringInfo str,
for (i = 0; i < indent; i++)
appendStringInfo(str, " ");
appendStringInfo(str, " -> ");
+ /*
+ * Ordinarily we don't pass down our own outer_plan value to our
+ * child nodes, but in bitmap scan trees we must, since the bottom
+ * BitmapIndexScan nodes may have outer references.
+ */
explain_outNode(str, outerPlan(plan),
outerPlanState(planstate),
- NULL,
+ IsA(plan, BitmapHeapScan) ? outer_plan : NULL,
indent + 3, es);
}
@@ -907,7 +912,7 @@ explain_outNode(StringInfo str,
explain_outNode(str, subnode,
bitmapandstate->bitmapplans[j],
- NULL,
+ outer_plan, /* pass down same outer plan */
indent + 3, es);
j++;
}
@@ -931,7 +936,7 @@ explain_outNode(StringInfo str,
explain_outNode(str, subnode,
bitmaporstate->bitmapplans[j],
- NULL,
+ outer_plan, /* pass down same outer plan */
indent + 3, es);
j++;
}