Message about not null in ALTER TABLE

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Message about not null in ALTER TABLE
Дата
Msg-id 1011595495.18821.18.camel@cm-lcon1-40-151.chello.cl
обсуждение исходный текст
Ответы Re: Message about not null in ALTER TABLE  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-bugs
I think this is a bug in the error message:

alvherre=> alter table test add column b int not null;
ERROR:  Adding NOT NULL columns is not implemented.
    Add the column, then use ALTER TABLE ADD CONSTRAINT.

However, there is no way to add a NOT NULL constraint to an existing
column in a table, so the error message is misleading.

alvherre=> alter table test add constraint bnotnull not null b;
ERROR:  parser: parse error at or near "not"

--
Alvaro Herrera (<alvherre[a]atentus.com>)
"Siempre hay que alimentar a los dioses, aunque la tierra este seca"
(Orual)

В списке pgsql-bugs по дате отправления:

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: 7.2b5 libpq++ include files broken?
Следующее
От: Chris Bainbridge
Дата:
Сообщение: bug in contrib-global.mk