deleting the master but not the detail

Поиск
Список
Период
Сортировка
От Ismael ....
Тема deleting the master but not the detail
Дата
Msg-id BLU103-W109AEF9B73C7C8336DC5C7A38E0@phx.gbl
обсуждение исходный текст
Ответы Re: deleting the master but not the detail  ("A. Kretschmer" <andreas.kretschmer@schollglas.com>)
Re: deleting the master but not the detail  (Raymond O'Donnell <rod@iol.ie>)
Re: deleting the master but not the detail  ("Douglas McNaught" <doug@mcnaught.org>)
Список pgsql-general
hi
I have one of those master-detail relationships here and I need to be able
to delete the master but leave the details untouched

But the delete command doesn't let me delete the master as long as
there are details referencing it.

ON DELETE RESTRICT | NO ACTION won't let me delete the master
CASCADE | SET NULL | SET DEFAULT will modify the details

Any idea ow to do it without the use of triggers?


SQL Server is got the option "ON DELETE DO NOTHING" or something
like that, that just oversees the deletion, but I didn't find it for postgres.
_________________________________________________________________
P.D. Checa las nuevas fotos de mi Space
http://home.services.spaces.live.com/

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

Предыдущее
От: "Kevin Duffy"
Дата:
Сообщение: query optimization
Следующее
От: Decibel!
Дата:
Сообщение: Re: [HACKERS] postmaster.pid not visible