From: Tom Lane <tgl@sss.pgh.pa.us>
To: Radoslav Nedyalkov <rnedyalkov@gmail.com>
Cc: Michael Lewis <mlewis@entrata.com>
Cc: pgsql-general <pgsql-general@postgresql.org>
Subject: Re: single table - fighting a seq scan
Date: Tue, 14 Jul 2020 18:06:04 -0400
Message-ID: <2980741.1594764364@sss.pgh.pa.us> (raw)
In-Reply-To: <CANhtRiaQ4HZR7D3_E3RayKH_zROJD_OSRe89eS5Y6cTrDZk6RA@mail.gmail.com>
References: <CANhtRiZMKJEHHK-Y6HEkYKHNULWshbks37EVDj=wLYdhZ0_rGA@mail.gmail.com>
<CAHOFxGqfRa7uPkG2dEv5U2rt_ZLORVvBYGXLK7t7ZG8HGQgeeQ@mail.gmail.com>
<CANhtRiYzw79GB49fvK3GEn5X9i=sbeVH2SOOKe0nM=Hd7yt2Mg@mail.gmail.com>
<CANhtRiaQ4HZR7D3_E3RayKH_zROJD_OSRe89eS5Y6cTrDZk6RA@mail.gmail.com>
Radoslav Nedyalkov <rnedyalkov@gmail.com> writes:
> Ah, I could have messed up the examples I gave. Row numbers are different.
> Once again the plans , sorry about that.
Given that it works at 100 entries and not 101, I can't escape the
suspicion that you're being burnt by predtest.c's MAX_SAOP_ARRAY_SIZE
limit. However, that only affects the planner's willingness to make
constraint proofs involving the large IN clause, and nothing you've
mentioned here explains why such a proof would be needed. Is there
something you're not telling us about this table's schema? (I'm
wondering if the index is partial, for instance, though one would
think that the CTE form of the query wouldn't work either if so.)
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: tgl@sss.pgh.pa.us, rnedyalkov@gmail.com, mlewis@entrata.com
Subject: Re: single table - fighting a seq scan
In-Reply-To: <2980741.1594764364@sss.pgh.pa.us>
References: <CANhtRiZMKJEHHK-Y6HEkYKHNULWshbks37EVDj=wLYdhZ0_rGA@mail.gmail.com> <CAHOFxGqfRa7uPkG2dEv5U2rt_ZLORVvBYGXLK7t7ZG8HGQgeeQ@mail.gmail.com> <CANhtRiYzw79GB49fvK3GEn5X9i=sbeVH2SOOKe0nM=Hd7yt2Mg@mail.gmail.com> <CANhtRiaQ4HZR7D3_E3RayKH_zROJD_OSRe89eS5Y6cTrDZk6RA@mail.gmail.com> <2980741.1594764364@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox