Re: DROP COLUMN

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: Hiroshi Inoue <Inoue(at)tpf(dot)co(dot)jp>, Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au>, Rod Taylor <rbt(at)zort(dot)ca>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: DROP COLUMN
Date: 2002-07-17 04:04:01
Message-ID: 10901.1026878641@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:
>> What I asked you is what *harder to fix* means.

> Uh, some said that having attno's like 1,2,3,5,7,8,9 with gaps would
> cause coding problems in client applications, and that was easier to
> have the numbers as 1-9 and check a flag if the column is dropped. Why
> that is easier than having gaps, I don't understand. I voted for the
> gaps (with negative attno's) but client coders liked the flag, so we
> went with that.

It seems to me that the problems Chris is noticing have to do with
gaps in the sequence of valid (positive) attnums. I don't believe that
the negative-attnum approach to marking deleted columns would make those
issues any easier (or harder) to fix. Either way you have a gap.

But since the historical convention is "negative attnum is a system
column", and deleted columns are *not* system columns, I prefer the idea
of using a separate marker for deleted columns. AFAICT the comments
from application coders have also been that they don't want to confuse
these two concepts.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2002-07-17 04:10:31 Re: Do we still need these NOTICEs?
Previous Message Bruce Momjian 2002-07-17 03:24:25 Re: Do we still need these NOTICEs?