So the result of all this is that the behaviour of my ADD UNIQUE code is correct in this case?
> Peter Eisentraut <[EMAIL PROTECTED]> writes: > > Shouldn't this work? > > create table test ( a int, unique (oid) ); > > ERROR: CREATE TABLE: column "oid" named in key does not exist > > Now it does. In 7.2 you mean? Or did you just fix it then? > > And shouldn't the last one say "ALTER"? > > The reason that happens is that parser/analyze.c transforms the command > into an ALTER TABLE step that adds a constraint (a no-op in this case) > plus a CREATE INDEX step. The commandTag emitted by the last step is > what psql shows. This could possibly be fixed, but it seems not worth > the trouble. If it were to be changed - I really wouldn't know where to do that... Chris ---------------------------(end of broadcast)--------------------------- TIP 3: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED] so that your message can get through to the mailing list cleanly