Re: Changing from NOT NULL to NULL - Mailing list pgsql-novice

From Nabil Sayegh
Subject Re: Changing from NOT NULL to NULL
Date
Msg-id 402FFED6.40808@e-trolley.de
Whole thread Raw
In response to Changing from NOT NULL to NULL  (Rob Mosher <mosher@andrews.edu>)
List pgsql-novice
Rob Mosher wrote:
> Is there anyway I can change a field to allowing nulls without dumping
> the table, dropping it, recreating it as desired, and filling all the
> data back in?

ALTER TABLE tab ALTER COLUMN col DROP NOT NULL;

HTH
--
  e-Trolley Sayegh & John, Nabil Sayegh
  Tel.: 0700 etrolley /// 0700 38765539
  Fax.: +49 69 8299381-8
  PGP : http://www.e-trolley.de

pgsql-novice by date:

Previous
From: Michael Glaesemann
Date:
Subject: Re: Changing from NOT NULL to NULL
Next
From: Tom Lane
Date:
Subject: Re: Changing from NOT NULL to NULL