Thanks to visit codestin.com
Credit goes to postgrespro.com

Re: Slow query - possible bug? - Mailing list pgsql-performance

From Tom Lane
Subject Re: Slow query - possible bug?
Date
Msg-id [email protected]
Whole thread Raw
In response to Re: Slow query - possible bug?  (Gavin Hamill <[email protected]>)
Responses Re: Slow query - possible bug?
List pgsql-performance
Gavin Hamill <[email protected]> writes:
> On Tue, 18 Apr 2006 13:31:48 -0400
> Tom Lane <[email protected]> wrote:
>> There should be a fix for this by the time PG 8.2 comes out, but in
>> the meantime you might find that it helps to write the range check in
>> a way that doesn't have identical bounds, eg
>> date >= '2006-06-10'::date AND date < '2006-06-11'::date

> OK coolies - we've already had a code release for this (and other
> stuff) planned for tomorrow morning checking on the client side
> if a single date has been chosen, then do an equality test on that...

Fair enough, no reason to replace one workaround with another.  But
would you try it on your test case, just to verify the diagnosis?

            regards, tom lane

pgsql-performance by date:

Previous
From: Gavin Hamill
Date:
Subject: Re: Slow query - possible bug?
Next
From: "Jim C. Nasby"
Date:
Subject: Re: index is not used if I include a function that returns current time in my query