Re: BETWEEN Node & DROP COLUMN - Mailing list pgsql-hackers

From Alvaro Herrera
Subject Re: BETWEEN Node & DROP COLUMN
Date
Msg-id Pine.LNX.4.44.0207050250190.19948-100000@cm-lcon-46-187.cm.vtr.net
Whole thread Raw
In response to Re: BETWEEN Node & DROP COLUMN  ("Christopher Kings-Lynne" <chriskl@familyhealth.com.au>)
Responses Re: BETWEEN Node & DROP COLUMN  ("Christopher Kings-Lynne" <chriskl@familyhealth.com.au>)
List pgsql-hackers
Christopher Kings-Lynne dijo: 

> > > 2. What should I do about inheritance?  I'm going to implement 
> > it, but are
> > > there issues?  It will basically drop the column with the same 
> > name in all
> > > child tables.  Is that correct behaviour?
> > 
> > What happens if I drop an inherited column in a child table?  Maybe it
> > works, but what happens when I SELECT the column in the parent table?
> 
> I don't know?  Tom?
> 
> Well, what happens if you rename a column in a child table?  Same problem?

It merrily renames the column in the child table (I tried it).  When
SELECTing the parent, bogus data appears.  Looks like a bug to me.
Maybe the ALTER TABLE ...  RENAME COLUMN code should check for inherited
columns before renaming them.

-- 
Alvaro Herrera (<alvherre[a]atentus.com>)
One man's impedance mismatch is another man's layer of abstraction.
(Lincoln Yeoh)






pgsql-hackers by date:

Previous
From: "Christopher Kings-Lynne"
Date:
Subject: Re: BETWEEN Node & DROP COLUMN
Next
From: "Christopher Kings-Lynne"
Date:
Subject: Re: BETWEEN Node & DROP COLUMN