1
0
mirror of https://github.com/postgres/postgres.git synced 2025-06-13 07:41:39 +03:00

Change expandRTE() and ResolveNew() back to taking just the single

RTE of interest, rather than the whole rangetable list.  This makes
the API more understandable and avoids duplicate RTE lookups.  This
patch reverts no-longer-needed portions of my patch of 2004-08-19.
This commit is contained in:
Tom Lane
2005-06-04 19:19:42 +00:00
parent fb91a83e0e
commit e18e8f8735
11 changed files with 92 additions and 94 deletions

View File

@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/parser/parse_clause.c,v 1.140 2005/04/13 16:50:55 tgl Exp $
* $PostgreSQL: pgsql/src/backend/parser/parse_clause.c,v 1.141 2005/06/04 19:19:42 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@ -663,7 +663,8 @@ transformFromClauseItem(ParseState *pstate, Node *n, List **containedRels)
elog(ERROR, "unrecognized node type: %d", (int) nodeTag(j->larg));
leftrti = 0; /* keep compiler quiet */
}
expandRTE(pstate->p_rtable, leftrti, 0, false,
rte = rt_fetch(leftrti, pstate->p_rtable);
expandRTE(rte, leftrti, 0, false,
&l_colnames, &l_colvars);
if (IsA(j->rarg, RangeTblRef))
@ -675,7 +676,8 @@ transformFromClauseItem(ParseState *pstate, Node *n, List **containedRels)
elog(ERROR, "unrecognized node type: %d", (int) nodeTag(j->rarg));
rightrti = 0; /* keep compiler quiet */
}
expandRTE(pstate->p_rtable, rightrti, 0, false,
rte = rt_fetch(rightrti, pstate->p_rtable);
expandRTE(rte, rightrti, 0, false,
&r_colnames, &r_colvars);
/*