diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2007-02-19 02:23:12 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2007-02-19 02:23:12 +0000 |
commit | b8c326779246d6554a0868270639714cc4989a0e (patch) | |
tree | 886a2bb16966a9c3ef9e29a2a8767a98f46fa0dd /src/backend/optimizer/plan/subselect.c | |
parent | f1f2b2711a4c91064a5e64def9816c11f1bd4276 (diff) | |
download | postgresql-b8c326779246d6554a0868270639714cc4989a0e.tar.gz |
Put function expressions and values lists into FunctionScan and ValuesScan
plan nodes, so that the executor does not need to get these items from
the range table at runtime. This will avoid needing to include these
fields in the compact range table I'm expecting to make the executor use.
Diffstat (limited to 'src/backend/optimizer/plan/subselect.c')
-rw-r--r-- | src/backend/optimizer/plan/subselect.c | 22 |
1 files changed, 5 insertions, 17 deletions
diff --git a/src/backend/optimizer/plan/subselect.c b/src/backend/optimizer/plan/subselect.c index e79991a0f6..af035d9b10 100644 --- a/src/backend/optimizer/plan/subselect.c +++ b/src/backend/optimizer/plan/subselect.c @@ -7,7 +7,7 @@ * Portions Copyright (c) 1994, Regents of the University of California * * IDENTIFICATION - * $PostgreSQL: pgsql/src/backend/optimizer/plan/subselect.c,v 1.118 2007/02/06 02:59:11 tgl Exp $ + * $PostgreSQL: pgsql/src/backend/optimizer/plan/subselect.c,v 1.119 2007/02/19 02:23:12 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -1103,25 +1103,13 @@ finalize_plan(Plan *plan, List *rtable, break; case T_FunctionScan: - { - RangeTblEntry *rte; - - rte = rt_fetch(((FunctionScan *) plan)->scan.scanrelid, - rtable); - Assert(rte->rtekind == RTE_FUNCTION); - finalize_primnode(rte->funcexpr, &context); - } + finalize_primnode(((FunctionScan *) plan)->funcexpr, + &context); break; case T_ValuesScan: - { - RangeTblEntry *rte; - - rte = rt_fetch(((ValuesScan *) plan)->scan.scanrelid, - rtable); - Assert(rte->rtekind == RTE_VALUES); - finalize_primnode((Node *) rte->values_lists, &context); - } + finalize_primnode((Node *) ((ValuesScan *) plan)->values_lists, + &context); break; case T_Append: |