Re: Help with ADD COLUMN - Mailing list pgsql-hackers

From Rod Taylor
Subject Re: Help with ADD COLUMN
Date
Msg-id 1038147884.65346.6.camel@jester
Whole thread Raw
In response to Re: Help with ADD COLUMN  (Hannu Krosing <hannu@tm.ee>)
List pgsql-hackers
On Sun, 2002-11-24 at 11:14, Hannu Krosing wrote:
> On Sun, 2002-11-24 at 08:34, Philip Warner wrote:
> > At 03:48 PM 23/11/2002 -0800, Christopher Kings-Lynne wrote:
> > >I assume that's the correct behaviour?  If they specify a default, the
> > >column should be auto-filled with that default, right?
> > 
> > Good question. We might want some input from other DBs; Dec RDB default 
> > existing rows to NULL irrespective of the 'DEFAULT' clause.
> 
> Also, how would I express a new column with default for which I _want_ 
> that column in old records to be NULL ?

Same way as you do now.  Add the column, then alter in the default.

-- 
Rod Taylor <rbt@rbt.ca>



pgsql-hackers by date:

Previous
From: Hannu Krosing
Date:
Subject: Re: Help with ADD COLUMN
Next
From: Tom Lane
Date:
Subject: Re: Help with ADD COLUMN