Re: [HACKERS] DROP COLUMN misbehaviour with multiple inheritance

From: Alvaro Herrera <alvherre(at)atentus(dot)com>
To: pgsql-patches(at)postgresql(dot)org
Subject: Re: [HACKERS] DROP COLUMN misbehaviour with multiple inheritance
Date: 2002-09-13 02:13:15
Message-ID: Pine.LNX.4.44.0209122204050.3103-200000@cm-lcon1-46-187.cm.vtr.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers pgsql-patches

Alvaro Herrera dijo:

> All right, I now have all the catalog changes on place; this is the easy
> part (is an int2 count enough?).
>
> But when actually dropping a column, the recursion cannot be done the
> way it's done now, fetching the whole inheritor tree in one pass,
> because there's no way to distinguish the direct ones that have the
> attisinherited count greater than 1 from deeper ones; it has to be done
> step by step.

Done. I attach the patch. It's huge because it needs to touch
pg_attribute.h, but it is relatively simple. This passes the regression
tests and fixes the bug reported by Hannu.

Please review and apply if OK. I didn't touch catversion.h.

--
Alvaro Herrera (<alvherre[a]atentus.com>)
"Cuando mañana llegue pelearemos segun lo que mañana exija" (Mowgli)

Attachment Content-Type Size
attisinh-int2.patch text/plain 47.4 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2002-09-13 02:52:40 Re: DROP COLUMN misbehaviour with multiple inheritance
Previous Message Alvaro Herrera 2002-09-13 01:14:14 Re: DROP COLUMN misbehaviour with multiple inheritance

Browse pgsql-patches by date

  From Date Subject
Next Message Alvaro Herrera 2002-09-13 02:52:40 Re: DROP COLUMN misbehaviour with multiple inheritance
Previous Message Alvaro Herrera 2002-09-13 01:14:14 Re: DROP COLUMN misbehaviour with multiple inheritance