Re: Foreign keys and indexes - Mailing list pgsql-general

From Richard Broersma Jr
Subject Re: Foreign keys and indexes
Date
Msg-id 698551.87665.qm@web31807.mail.mud.yahoo.com
Whole thread Raw
In response to Foreign keys and indexes  (Marc Compte <mcompte@sigte.udg.es>)
Responses Re: Foreign keys and indexes  (Marc Compte <mcompte@sigte.udg.es>)
List pgsql-general
> Does PostgreSQL create an implicit index also for foreign keys? or must
> I create it explicitly?

No, you foreign keys are not automatically indexed.  They only way they would be is if the FK is
part of a composite unique or primary key.  So you will probably have to create your one indexes
on FKs.

Regards,
Richard Broersma Jr.


pgsql-general by date:

Previous
From: Ranieri Mazili
Date:
Subject: CREATE RULE with WHERE clause
Next
From: Ragnar
Date:
Subject: Re: Foreign keys and indexes