On Mon, 2005-03-14 at 10:02 +0100, PFC wrote: > If you want to add a SERIAL field to an existing table, create a > sequence > and then create an integer field with default nextval(seq) and postgres > will fill it automatically. The order in which it will fill it is not > guaranteed though !
With 8.0, Alter Table supports most complicated commands including the addition of SERIAL directly. alter table abc add column bob serial NOT NULL UNIQUE; -- ---------------------------(end of broadcast)--------------------------- TIP 8: explain analyze is your friend