Re: Rearranging simple where clauses - Mailing list pgsql-general

From Michael Graham
Subject Re: Rearranging simple where clauses
Date
Msg-id 1304524731.24106.57.camel@brutus
Whole thread Raw
In response to Re: Rearranging simple where clauses  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Rearranging simple where clauses
List pgsql-general
On Wed, 2011-05-04 at 11:49 -0400, Tom Lane wrote:
> Well, you failed to show us any concrete examples of the cases you
> were looking at, but no I don't think the planner necessarily likes
> "all the constants on one side".  Most likely the win cases are where
> one side of a WHERE-condition operator exactly matches an index, so
> you'd need to be looking for places where rearrangement could make
> that happen.

The reason I never showed you any was because I don't have any I was
just curious.  But yeah making one side match an index exactly is
probably the biggest win.

--
Michael Graham <mgraham@bloxx.com>



pgsql-general by date:

Previous
From: Marek Więckowski
Date:
Subject: Re: auto-reconnect: temp schemas, sequences, transactions
Next
From: Tom Lane
Date:
Subject: Re: auto-reconnect: temp schemas, sequences, transactions