From: | Bruno Wolff III <bruno(at)wolff(dot)to> |
---|---|
To: | David Gagnon <dgagnon(at)siunik(dot)com> |
Cc: | Stephan Szabo <sszabo(at)megazone(dot)bigpanda(dot)com>, pgsql-performance(at)postgresql(dot)org |
Subject: | Re: Why the planner is not using the INDEX . |
Date: | 2005-07-05 12:32:17 |
Message-ID: | 20050705123217.GA11379@wolff.to |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-performance |
On Mon, Jul 04, 2005 at 20:29:50 -0400,
David Gagnon <dgagnon(at)siunik(dot)com> wrote:
> Thanks .. I miss that FK don't create indexed ... since Primary key
> implicitly does ...
>
> I'm a bit surprised of that behavior thought, since it means that if we
> delete a row from table A all tables (B,C,D) with FK pointing to this
> table (A) must be scanned.
But in some applications you don't ever do that, so you don't save
anything by having the index for deletes but have to pay the cost to
update it when modifying the referencing table.
If you think an index will help in your case, just create one.
From | Date | Subject | |
---|---|---|---|
Next Message | Stephan Szabo | 2005-07-05 14:02:07 | Re: Why the planner is not using the INDEX . |
Previous Message | Christopher Kings-Lynne | 2005-07-05 01:13:30 | Re: Why the planner is not using the INDEX . |