Re: Foreign Key Columns And Indices
От | Jan Wieck |
---|---|
Тема | Re: Foreign Key Columns And Indices |
Дата | |
Msg-id | 200102061257.HAA01022@jupiter.greatbridge.com обсуждение исходный текст |
Ответ на | Re: Foreign Key Columns And Indices (Stephan Szabo <sszabo@megazone23.bigpanda.com>) |
Список | pgsql-hackers |
Stephan Szabo wrote: > > On Mon, 5 Feb 2001, Christopher Kings-Lynne wrote: > > > Just a quick question, when a column of a table is defined to be a foreign > > key, is it implicitly indexed, or does one still need to explicitly CREATE > > INDEX? > > The foreign key columns are not currently implicitly indexed but you may > wish to index them if you're using a referential action other than no > action or restrict. You'd probably want to index them either way, because even "NO ACTION" and "RESTRICT" mean that a scan for existing references is done on updates/deletes to the PK. Jan -- #======================================================================# # It's easier to get forgiveness for being wrong than for being right. # # Let's break this rule - forgive me. # #================================================== JanWieck@Yahoo.com # _________________________________________________________ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com
В списке pgsql-hackers по дате отправления: