In this email http://archives.postgresql.org/pgsql-bugs/2006-03/msg00076.php belonging to bug #2310, Tom says
> I wrote: > > The relevant owner field for a composite type is pg_type.typowner. > > We don't bother to maintain pg_class.relowner for the subsidiary > > pg_class entry. > > Actually, now that I look at it, there is a non-cosmetic issue here: > we seem to be creating a dependency link for the pg_class owner field. > We have to either not do that, or be willing to fix it during ALTER TYPE > OWNER. This patch fixes this problem, by inhibiting the recording of the owner in pg_shdepend for a RELKIND_COMPOSITE_TYPE relation (i.e. the first solution proposed above). I intend to apply it to 8.1 and current trunk, later today. -- Alvaro Herrera http://www.CommandPrompt.com/ PostgreSQL Replication, Consulting, Custom Development, 24x7 support
Index: src/backend/catalog/heap.c =================================================================== RCS file: /home/alvherre/cvs/pgsql/src/backend/catalog/heap.c,v retrieving revision 1.295 diff -c -r1.295 heap.c *** src/backend/catalog/heap.c 5 Mar 2006 15:58:22 -0000 1.295 --- src/backend/catalog/heap.c 2 Apr 2006 22:20:10 -0000 *************** *** 772,778 **** referenced.objectSubId = 0; recordDependencyOn(&myself, &referenced, DEPENDENCY_NORMAL); ! recordDependencyOnOwner(RelationRelationId, relid, ownerid); } /* --- 772,784 ---- referenced.objectSubId = 0; recordDependencyOn(&myself, &referenced, DEPENDENCY_NORMAL); ! /* ! * For composite types, the dependency on owner is tracked for the ! * pg_type entry, so don't record it here. All other relkinds need ! * their ownership tracked. ! */ ! if (relkind != RELKIND_COMPOSITE_TYPE) ! recordDependencyOnOwner(RelationRelationId, relid, ownerid); } /*
---------------------------(end of broadcast)--------------------------- TIP 1: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED] so that your message can get through to the mailing list cleanly