Re: contrib idea

Поиск
Список
Период
Сортировка
От Christopher Kings-Lynne
Тема Re: contrib idea
Дата
Msg-id GNELIHDDFBOCMGBFGEFOKEOECAAA.chriskl@familyhealth.com.au
обсуждение исходный текст
Ответ на Re: contrib idea  (Bruce Momjian <pgman@candle.pha.pa.us>)
Список pgsql-hackers
If you have a foreign key on a column, then whenever the primary key is
modified, the following checks may occur:

* Check to see if the child row exists (no action)
* Delete the child row (cascade delete)
* Update the child row (cascade update)

All of which will benefit from an index...

Chris

> -----Original Message-----
> From: Bruce Momjian [mailto:pgman@candle.pha.pa.us]
> Sent: Friday, 21 December 2001 11:59 AM
> To: Christopher Kings-Lynne
> Cc: Hackers
> Subject: Re: [HACKERS] contrib idea
>
>
> > Hi All,
> >
> > You know how when you create a foreign key in postgres it isn't
> > automatically indexed, and it seems to me that it's very useful to have
> > indexed foreign keys, especially if you use lots of them.
> >
> > So, how about a 'findslowfks' contrib?  This would basically be
> similar to
> > Bruce's findoidjoins thingy...
>
> Why would you want an index on a foreign key.  Primary I can understand,
> but is there use to foreignt?  Is it for checking of changes to primary
> keys?
>
> --
>   Bruce Momjian                        |  http://candle.pha.pa.us
>   pgman@candle.pha.pa.us               |  (610) 853-3000
>   +  If your life is a hard drive,     |  830 Blythe Avenue
>   +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026
>



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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: The dbase conrtib doesn't compile
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: TOAST performance (was Re: [GENERAL] Delete Performance)