Re: Sub-optimal plan chosen

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Sep 10, 2009 at 10:02 AM, Robert Haas <robertmhaas@xxxxxxxxx> wrote:
On Thu, Sep 10, 2009 at 12:56 PM, bricklen <bricklen@xxxxxxxxx> wrote:
> On Thu, Sep 10, 2009 at 8:43 AM, Tom Lane <tgl@xxxxxxxxxxxxx> wrote:
>>
>> bricklen <bricklen@xxxxxxxxx> writes:
>> > Is there any other data I can provide to shed some light on this?
>>
>> The table and index definitions?
>>
>> The straight indexscan would probably win if the index column order
>> were ofid, date instead of date, ofid.  I can't tell if you have
>> any other queries for which the existing column order is preferable,
>> though.
>>
>>                        regards, tom lane
>
>
> Changing the order of the WHERE predicates didn't help.

He's talking about the index definition, not the WHERE clause.  The
order of the WHERE clause is totally irrelevant.


Ah, sorry, missed that.

[Postgresql General]     [Postgresql PHP]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Yosemite]

  Powered by Linux