Re: ALTER TABLE with TYPE serial does not work - Mailing list pgsql-general

From Grzegorz Jaśkiewicz
Subject Re: ALTER TABLE with TYPE serial does not work
Date
Msg-id 2f4958ff0902010305x120b0ae8p7e687b0d4850eb2c@mail.gmail.com
Whole thread Raw
In response to Re: ALTER TABLE with TYPE serial does not work  (Scott Marlowe <scott.marlowe@gmail.com>)
List pgsql-general
all you have to really do is:

create sequence foo_bar_new_column_tralala_seq;
ALTER TABLE foo_bar ADD COLUMN tralala int NOT NULL DEFAULT
nextval('foo_bar_new_column_tralala_seq');

That's all there's to it

pgsql-general by date:

Previous
From: Jasen Betts
Date:
Subject: Re: Serial Jumping
Next
From: Grzegorz Jaśkiewicz
Date:
Subject: Re: Pet Peeves