public inbox for [email protected]
help / color / mirror / Atom feedFrom: Tom Lane <[email protected]>
To: Frédéric Yhuel <[email protected]>
Cc: [email protected] <[email protected]>
Cc: Jehan-Guillaume de Rorthais <[email protected]>
Cc: Christophe Courtois <[email protected]>
Cc: Laurenz Albe <[email protected]>
Subject: Re: Indexes on expressions with multiple columns and operators
Date: Thu, 18 Sep 2025 11:32:29 -0400
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>
<[email protected]>
<[email protected]>
=?UTF-8?Q?Fr=C3=A9d=C3=A9ric_Yhuel?= <[email protected]> writes:
> On 9/17/25 16:41, Tom Lane wrote:
>> =?UTF-8?Q?Fr=C3=A9d=C3=A9ric_Yhuel?= <[email protected]> writes:
>>> 2) the number of estimated rows is completely off in the second EXPLAIN,
>>> whereas the planner could easily use the statistics of foo_f_idx.
>> Hmm, not sure about that. Again, boolean-valued indexes aren't
>> something we've worked on too hard, but I don't see why that
>> would affect this case.
> OK, thanks anyway, I think the ju-jitsu mentioned above will do, even
> though the application code will have to be patched.
Sigh ... so the answer is this used to work (since commit 39df0f150)
and then I carelessly broke it in commit a391ff3c3. If you try this
test case in versions 9.5..11 you get a spot-on rowcount estimate.
Serves me right for not having a test case I guess, but I'm astonished
that nobody complained sooner.
regards, tom lane
view thread (26+ messages) latest in thread
reply
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 using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
Subject: Re: Indexes on expressions with multiple columns and operators
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox