public inbox for [email protected]
help / color / mirror / Atom feedFrom: Tom Lane <[email protected]>
To: Sbob <[email protected]>
Cc: Rui DeSousa <[email protected]>
Cc: [email protected] <[email protected]>
Subject: Re: checking for a NULL date in a partitioned table kills performance
Date: Thu, 22 Aug 2024 20:05:19 -0400
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>
<[email protected]>
<[email protected]>
<[email protected]>
Sbob <[email protected]> writes:
> 29 million of the 32 million rows in the table have NULL for contract_date
[ blink... ] So your query is selecting at least 29/32nds of the
table, plus however much matches the contract_date > '2022-01-01'
alternative. I'm not sure how you expect that to be significantly
cheaper than scanning the whole table.
regards, tom lane
view thread (16+ 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]
Subject: Re: checking for a NULL date in a partitioned table kills performance
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