From: | Gaetano Mendola <mendola(at)bigfoot(dot)com> |
---|---|
To: | Thomas Zehetbauer <thomasz(at)hostmaster(dot)org> |
Subject: | Re: add column sillyness |
Date: | 2003-12-10 01:21:53 |
Message-ID: | 3FD67531.8090900@bigfoot.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Thomas Zehetbauer wrote:
> Why do I have to use FOUR queries to accomplish the same result I can
> get from MySQL with only ONE query:
>
> alter table users add column $ColumnName text;
> alter table users alter column $ColumnName set default '';
> update users set t_shirt_size='' where $ColumnName is null;
> alter table users alter column $ColumnName set not null;
Wow, that's true!
On MySQL 4.0.16-nt is also possible write:
alter table T1
add CONSTRAINT FK_test foreign key (id)
REFERENCES T2 (id);
that doesn't complain. Unfortunately repeating
the command N times doesn't complain neither.
And the funny here is that FK are not yet supported !
No regards.
Gaetano Mendola
From | Date | Subject | |
---|---|---|---|
Next Message | Martijn van Oosterhout | 2003-12-10 04:10:43 | Determining what a user can access |
Previous Message | Uwe C. Schroeder | 2003-12-10 01:16:40 | Re: Oracle to PostgreSQL migration |