Re: FW: Query length limitation in postgres server > 8.2.9

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Greg Stark <gsstark(at)mit(dot)edu>
Cc: jacob(at)aers(dot)ca, pgsql-sql(at)postgresql(dot)org
Subject: Re: FW: Query length limitation in postgres server > 8.2.9
Date: 2009-07-08 00:58:20
Message-ID: 3760.1247014700@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Greg Stark <gsstark(at)mit(dot)edu> writes:
> On Tue, Jul 7, 2009 at 11:33 PM, <jacob(at)aers(dot)ca> wrote:
>> After some investigation it seems that the new server is refusing to use the index's but if I
>> limit the number of arguments in the latter part of the statement to 100 then it works as
>> expected in the expected amount of time using the indexs.

> Ugh, I thought this sounded familiar. I think you're hitting this
> limit which was put in place in 8.2.12 to protect against very slow
> planning times for very long IN lists:

Nonsense ... unless perhaps the index is partial, and the IN condition
is relevant to proving it's legal to use the index? Given the lack of
any schema information in the complaint, I suppose I can't rule that
out, but one would hope the OP would have mentioned such a thing.

regards, tom lane

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message nha 2009-07-08 09:30:16 Re: Recording how a table is used
Previous Message Greg Stark 2009-07-08 00:43:06 Re: FW: Query length limitation in postgres server > 8.2.9