From: Dean Rasheed <dean.a.rasheed@gmail.com>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Improve estimation of ANDs under ORs using extended statistics.
Date: Tue, 08 Dec 2020 20:12:02 +0000
Message-ID: <E1kmjL8-00024D-6u@gemulon.postgresql.org> (raw)
Improve estimation of ANDs under ORs using extended statistics.
Formerly, extended statistics only handled clauses that were
RestrictInfos. However, the restrictinfo machinery doesn't create
sub-AND RestrictInfos for AND clauses underneath OR clauses.
Therefore teach extended statistics to handle bare AND clauses,
looking for compatible RestrictInfo clauses underneath them.
Dean Rasheed, reviewed by Tomas Vondra.
Discussion: https://postgr.es/m/CAEZATCW=J65GUFm50RcPv-iASnS2mTXQbr=CfBvWRVhFLJ_fWA@mail.gmail.com
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/4f5760d4afa9423fe4d38e4cbec48bf5e793e7e5
Modified Files
--------------
src/backend/optimizer/path/clausesel.c | 21 +++++++++++++++++++++
src/backend/statistics/extended_stats.c | 25 +++++++++++++++++++++++++
src/test/regress/expected/stats_ext.out | 4 ++--
3 files changed, 48 insertions(+), 2 deletions(-)
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-committers@postgresql.org
Cc: dean.a.rasheed@gmail.com
Subject: Re: pgsql: Improve estimation of ANDs under ORs using extended statistics.
In-Reply-To: <E1kmjL8-00024D-6u@gemulon.postgresql.org>
References: <E1kmjL8-00024D-6u@gemulon.postgresql.org>
* 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