Re: Alter table add column ignores default

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Vince Vielhaber <vev(at)michvhf(dot)com>
Cc: Nabil Sayegh <nsmail(at)sayegh(dot)de>, vev(at)hub(dot)org, pgsql-bugs(at)postgresql(dot)org
Subject: Re: Alter table add column ignores default
Date: 2001-05-11 13:47:06
Message-ID: 4188.989588826@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Vince Vielhaber <vev(at)michvhf(dot)com> writes:
> If this:
> alter table foobar add column address varchar(50) default 'none';
> is the incorrect syntax, why does it not fail or at least give a
> warning?

Because it's incompletely implemented: the parser takes the full syntax
but the ALTER TABLE routine doesn't do everything it should.

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2001-05-11 13:57:41 Re: SELECT updatability clause defective.
Previous Message Thomas Lockhart 2001-05-11 13:45:37 Re: createdb test shown as number in data directory