From: Tom Lane <tgl@sss.pgh.pa.us>
To: Ashutosh Bapat <ashutosh.bapat@enterprisedb.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: Account for cost and selectivity of HAVING quals
Date: Wed, 01 Nov 2017 11:11:54 -0400
Message-ID: <9878.1509549114@sss.pgh.pa.us> (raw)
In-Reply-To: <CAFjFpRe_C8KfOGnKXz19PqwUFFY4=HrVz+12_G9-8TtZRaFikQ@mail.gmail.com>
References: <20968.1509486337@sss.pgh.pa.us>
<CAFjFpRe_C8KfOGnKXz19PqwUFFY4=HrVz+12_G9-8TtZRaFikQ@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>
Ashutosh Bapat <ashutosh.bapat@enterprisedb.com> writes:
> On Wed, Nov 1, 2017 at 3:15 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> here's a patch to fix the planner so that eval costs and selectivity of
>> HAVING quals are factored into the appropriate plan node numbers.
>> ...
>> + /* Add cost of qual, if any --- but we ignore its selectivity */
> And may be we should try to explain why can we ignore selectivity.
> Similarly for the changes in create_minmaxagg_path().
I'm sure you realize that's because the estimate is already just one
row ... but sure, we can spell that out.
regards, tom lane
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
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: pgsql-hackers@postgresql.org
Cc: tgl@sss.pgh.pa.us, ashutosh.bapat@enterprisedb.com
Subject: Re: Account for cost and selectivity of HAVING quals
In-Reply-To: <9878.1509549114@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