Re: [HACKERS] pg_attribute.attisinherited ?

From: Alvaro Herrera <alvherre(at)atentus(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-patches(at)postgresql(dot)org
Subject: Re: [HACKERS] pg_attribute.attisinherited ?
Date: 2002-08-31 05:52:59
Message-ID: 20020831015259.075b0515.alvherre@atentus.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

En Fri, 30 Aug 2002 15:29:45 -0400
Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> escribió:

> Alvaro Herrera <alvherre(at)atentus(dot)com> writes:
> > - Adds a new attribute in pg_attribute named attisinherited.
>
> I've applied this patch after a little editorializing. FYI ---
>
> * copyfuncs.c,equalfuncs.c,outfuncs.c,readfuncs.c needed to be updated
> for the field added to ColumnDef. In general, any time you alter the
> definition of a Node structure, you gotta update these files.

Ok, will make a note on that.

> * I didn't like having to touch all the callers of TupleDescInitEntry,
> so I just made it initialize attisinherited to false. In the one
> place where attisinherited might be set true, just update after return
> from TupleDescInitEntry.

Yes, I had thought of doing that. It's much simpler and cleaner.

> * Moved the checks for rename/drop ONLY with child tables into
> tablecmds.c instead of utility.c, so that they'd be applied after
> grabbing an exclusive lock on the table, not before. Otherwise a
> child could be added after you look.

Huh, that's where I had put them in the first place. I moved them to
tcop without thinking about the locking issues. I'll be more careful on
this also.

Thank you,

--
Alvaro Herrera (<alvherre[a]atentus.com>)
Voy a acabar con todos los humanos / con los humanos yo acabaré
voy a acabar con todos / con todos los humanos acabaré (Bender)

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Zhicong Leo Liang 2002-08-31 12:28:53 serial type as foreign key referential integrity violation
Previous Message Bruce Momjian 2002-08-31 05:42:11 Re: turning off autocommit behavior in psql

Browse pgsql-patches by date

  From Date Subject
Next Message Serguei Mokhov 2002-08-31 05:58:26 pg_dump: Russian NLS Update + pg_dumpall Typo Fix
Previous Message Neil Conway 2002-08-31 05:49:57 Re: create or replace rule/view (fwd)