Re: Modifying a foreign key constraint?

Поиск
Список
Период
Сортировка
От Marc Branchaud
Тема Re: Modifying a foreign key constraint?
Дата
Msg-id 45CCBB59.8070005@x2omedia.com
обсуждение исходный текст
Ответ на Re: Modifying a foreign key constraint?  (Richard Broersma Jr <rabroersma@yahoo.com>)
Ответы Re: Modifying a foreign key constraint?  (Richard Broersma Jr <rabroersma@yahoo.com>)
Список pgsql-general
Richard Broersma Jr wrote:
>
> Sure there is, you can preform multiple alterations in one statement:
>
> ALTER TABLE foo DROP CONSTRAINT foo_bar_id_fkey,
>                 ADD CONSTRAINT foo_bar_id_fkey
>                 FOREIGN KEY (bar_fkey)
>                 REFERENCES bar (id)
>                 ON DELETE CASCADE;

Doh!  That's perfectly fine, of course.

I was wondering if there might be something along the lines of an ALTER
CONSTRAINT clause, which could change a specific aspect of a constraint
without having to re-specify the whole thing.

        Marc

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

Предыдущее
От: "Merlin Moncure"
Дата:
Сообщение: Re: Postgres SQL Syntax
Следующее
От: Richard Broersma Jr
Дата:
Сообщение: Re: Modifying a foreign key constraint?