| От | brew@theMode.com |
|---|---|
| Тема | Re: Removing Rows in Foreign Keys |
| Дата | |
| Msg-id | Pine.BSF.4.58.0504040423000.86885@themode.com обсуждение |
| Ответ на | Re: Removing Rows in Foreign Keys (Michael Fuhr <mike@fuhr.org>) |
| Список | pgsql-novice |
Michael.....
> > Is there a SQL command that removes both a row in a table and the rows in
> > other tables that reference it or do I have to do it manually?
>
> If you define the foreign key constraints as ON DELETE CASCADE,
> then referencing rows will be automatically deleted when you DELETE
> the referenced row.
Ah Ha, thanks muchly!!! That's just what I was looking for.
brew
==========================================================================
Strange Brew (brew@theMode.com)
Check out my Stock Option Covered Call website http://www.callpix.com
and my Musician's Online Database Exchange http://www.TheMode.com
==========================================================================
В списке pgsql-novice по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера