Re: [GENERAL] adding SERIAL to a table

2003-09-04 Thread scott.marlowe
On Mon, 1 Sep 2003, Tom Lane wrote: > "Claudio Lapidus" <[EMAIL PROTECTED]> writes: > > So? Is there a way to add the sequence to an existing table? > > Sure. You have to break the SERIAL down to its component parts though. > Something like > > CREATE SEQUENCE seq; > ALTER TABLE tab

Re: [GENERAL] adding SERIAL to a table

2003-09-02 Thread Tom Lane
"Claudio Lapidus" <[EMAIL PROTECTED]> writes: > So? Is there a way to add the sequence to an existing table? Sure. You have to break the SERIAL down to its component parts though. Something like CREATE SEQUENCE seq; ALTER TABLE tab ADD COLUMN ser INTEGER; UPDATE tab SET s