Robert, Thanks for the review.
On Wed, Apr 13, 2011 at 08:01:17PM -0700, Robert Haas wrote: > I think you only need an AccessShareLock on InheritsRelationId, since > you are only selecting from it. True; fixed. > If we adopt the elsewhere-proposed approach of forbidding the use of > rowtypes to create typed tables, the circularity-checking logic here > can become simpler. I think it's not actually water-tight right now: > > rhaas=# create table a (x int); > CREATE TABLE > rhaas=# create table b of a; > CREATE TABLE > rhaas=# create table c () inherits (b); > CREATE TABLE > rhaas=# create table d of c; > CREATE TABLE > rhaas=# alter table a of d; > ALTER TABLE > > pg_dump is not happy with this situation. Good test case. Since we're going to forbid hanging a typed table off a table rowtype, I believe the circularity check becomes entirely superfluous. I'm suspicious that I'm missing some way to introduce problematic circularity using composite-typed columns, but I couldn't come up with a problematic example. The current check would not detect such a problem, if one does exist, anyway. When we're done with the relkind-restriction patch, I'll post a new version of this one. It will remove the circularity check and add a relkind check. nm -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers