Re: AW: ALTER TABLE DROP COLUMN

From: Chris <chris(at)bitmead(dot)com>
To: Hiroshi Inoue <Inoue(at)tpf(dot)co(dot)jp>
Cc: PostgreSQL Development <pgsql-hackers(at)postgreSQL(dot)org>
Subject: Re: AW: ALTER TABLE DROP COLUMN
Date: 2000-10-16 08:34:34
Message-ID: 39EABD9A.3C0DBD2E@bitmead.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hiroshi Inoue wrote:

> Certainly it would need 2x.
> However is ADD COLUMN DEFAULT really needed ?
> I would do as follows.
>
> ADD COLUMN (without default)
> UPDATE .. SET new_column = new default
> ALTER TABLE ALTER COLUMN SET DEFAULT

Well in current postgres that would use 2x. With WAL I presume that
would use a lot of log space and probably a lot more processing. But if
you can do the above you might as well support the right syntax.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Hiroshi Inoue 2000-10-16 08:57:14 Re: AW: ALTER TABLE DROP COLUMN
Previous Message Hiroshi Inoue 2000-10-16 08:21:09 Re: AW: ALTER TABLE DROP COLUMN