Re: Index on two columns not used

From: "Heikki Linnakangas" <heikki(at)enterprisedb(dot)com>
To: "Arnaud Lesauvage" <thewild(at)freesurf(dot)fr>
Cc: <pgsql-performance(at)postgresql(dot)org>
Subject: Re: Index on two columns not used
Date: 2006-10-18 14:50:35
Message-ID: 45363F3B.1080109@enterprisedb.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Arnaud Lesauvage wrote:
> It is quite typical, yes. It is the base query of a view. In fact, most
> views have a lot more joins (they join with all the upper-level tables).
> But 150ms is OK, indeed.

If the query using the view does anything more than a "SELECT * FROM
view", you should do an explain analyze of the query instead of the
definition of the view. The access plan might look very different.

--
Heikki Linnakangas
EnterpriseDB http://www.enterprisedb.com

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Arnaud Lesauvage 2006-10-18 15:05:48 Re: Index on two columns not used
Previous Message Atesz 2006-10-18 14:24:30 ACCESS EXCLUSIVE lock