1
0
mirror of https://github.com/postgres/postgres.git synced 2025-06-16 06:01:02 +03:00

A little further progress on schemas: push down RangeVars into

addRangeTableEntry calls.  Remove relname field from RTEs, since
it will no longer be a useful unique identifier of relations;
we want to encourage people to rely on the relation OID instead.
Further work on dumping qual expressions in EXPLAIN, too.
This commit is contained in:
Tom Lane
2002-03-22 02:56:37 +00:00
parent 56c9b73c1d
commit 108a0ec87d
33 changed files with 496 additions and 312 deletions

View File

@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/parser/parse_func.c,v 1.119 2002/03/21 16:01:06 tgl Exp $
* $Header: /cvsroot/pgsql/src/backend/parser/parse_func.c,v 1.120 2002/03/22 02:56:34 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@ -252,7 +252,7 @@ ParseFuncOrColumn(ParseState *pstate, char *funcname, List *fargs,
&sublevels_up);
if (rte == NULL)
rte = addImplicitRTE(pstate, refname);
rte = addImplicitRTE(pstate, (RangeVar *) arg);
vnum = RTERangeTablePosn(pstate, rte, &sublevels_up);
@ -281,7 +281,10 @@ ParseFuncOrColumn(ParseState *pstate, char *funcname, List *fargs,
}
}
toid = typenameTypeId(rte->relname);
toid = get_rel_type_id(rte->relid);
if (!OidIsValid(toid))
elog(ERROR, "Cannot find type OID for relation %u",
rte->relid);
/* replace RangeVar in the arg list */
lfirst(i) = makeVar(vnum,