pgsql/src/backend/commands (creatinh.c)

Started by Tom Laneover 25 years ago3 messagescomitters
Jump to latest
#1Tom Lane
tgl@sss.pgh.pa.us

Date: Wednesday, December 13, 2000 @ 19:41:09
Author: tgl

Update of /home/projects/pgsql/cvsroot/pgsql/src/backend/commands
from hub.org:/home/projects/pgsql/tmp/cvs-serv67536

Modified Files:
creatinh.c

----------------------------- Log Message -----------------------------

Change StoreCatalogInheritance() to work from a list of parent relation
OIDs rather than names. Aside from being simpler and faster, this way
doesn't blow up in the face of 'create temp table foo () inherits (foo)'.
Which is a rather odd thing to do, but it seems some people want to.

#2Peter Eisentraut
peter_e@gmx.net
In reply to: Tom Lane (#1)
Re: pgsql/src/backend/commands (creatinh.c)

tgl@postgresql.org writes:

Change StoreCatalogInheritance() to work from a list of parent relation
OIDs rather than names. Aside from being simpler and faster, this way
doesn't blow up in the face of 'create temp table foo () inherits (foo)'.
Which is a rather odd thing to do, but it seems some people want to.

Just wondering, is the "odd" thing here the 'temp', the empty column list,
or 2 times "foo"?

--
Peter Eisentraut peter_e@gmx.net http://yi.org/peter-e/

#3Tom Lane
tgl@sss.pgh.pa.us
In reply to: Peter Eisentraut (#2)
Re: pgsql/src/backend/commands (creatinh.c)

Peter Eisentraut <peter_e@gmx.net> writes:

tgl@postgresql.org writes:

Change StoreCatalogInheritance() to work from a list of parent relation
OIDs rather than names. Aside from being simpler and faster, this way
doesn't blow up in the face of 'create temp table foo () inherits (foo)'.
Which is a rather odd thing to do, but it seems some people want to.

Just wondering, is the "odd" thing here the 'temp', the empty column list,
or 2 times "foo"?

The latter. The failure case was

create table foo (...);
create temp table foo (...) inherits (foo);

the problem being that the temp table name mapping for the temp foo
was installed before we were done looking up its ancestors.

regards, tom lane