From: | "eladio rodriguez" <elarod_ad(at)hotmail(dot)com> |
---|---|
To: | bsmith(at)h-e(dot)com, pgsql-admin(at)postgresql(dot)org |
Subject: | Re: Changing NOT NULL condition on column |
Date: | 2003-05-24 16:31:02 |
Message-ID: | Law14-F94OKS31JRC1s00001317@hotmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
saludos.
en 7.3:
ALTER TABLE [ ONLY ] table [ * ]
ALTER [ COLUMN ] column { SET | DROP } NOT NULL
en 7.2 no funciona.
tendrias que drop la columna y recrearla.
>From: Bob Smith <bsmith(at)h-e(dot)com>
>To: pgsql-admin <pgsql-admin(at)postgresql(dot)org>
>Subject: [ADMIN] Changing NOT NULL condition on column
>Date: Tue, 20 May 2003 16:40:34 -0700
>
>
>I need to change the not-null restriction on some columns in a table, and
>this doesn't seem to be possible with ALTER TABLE. Is it safe to connect
>as superuser and update pg_attribute.attnotnull directly? Or is there a
>different way to do this, other than dropping/re-creating the whole table?
>
>I'm currently running 7.2.3, but will be upgrading soon so I'd like to know
>if this would work with 7.3 as well.
>
>Thanks!
>
>Bob Smith
>Hammett & Edison, Inc.
>bsmith(at)h-e(dot)com
>
>
>---------------------------(end of broadcast)---------------------------
>TIP 4: Don't 'kill -9' the postmaster
_________________________________________________________________
Charla con tus amigos en línea mediante MSN Messenger:
http://messenger.yupimsn.com/
From | Date | Subject | |
---|---|---|---|
Next Message | David A. Leedom | 2003-05-24 22:50:14 | Re: Postgress |
Previous Message | Sean Murphy | 2003-05-24 01:52:06 | Postgresql User Passwords - Help! |