Re: [PATCH] Overestimated filter cost and its mitigation

From: David Fetter <david(at)fetter(dot)org>
To: Yuto Hayamizu <y(dot)hayamizu(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: [PATCH] Overestimated filter cost and its mitigation
Date: 2017-09-17 18:18:54
Message-ID: 20170917181854.GA29268@fetter.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Sep 11, 2017 at 04:43:46PM +0900, Yuto Hayamizu wrote:
> Hi hackers,
>
> Currently, cost of a filter with multiple clauses is estimated by
> summing up estimated cost of each clause. As long as a filter
> consists of simple clauses and its cost is fairly small, it works
> fine. However, when there exists some heavy clauses (like SubQuery or
> user-defined functions) and most of tuples are filtered by other
> simple clauses, total cost is likely to be overestimated. An attached
> patch mitigates this overestimation by using selectivity estimation of
> subsets of clauses in a filter.

I've taken the liberty of adding this to the upcoming commitfest.

Best,
David.
--
David Fetter <david(at)fetter(dot)org> http://fetter.org/
Phone: +1 415 235 3778 AIM: dfetter666 Yahoo!: dfetter
Skype: davidfetter XMPP: david(dot)fetter(at)gmail(dot)com

Remember to vote!
Consider donating to Postgres: http://www.postgresql.org/about/donate

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Christoph Berg 2017-09-17 18:22:44 Re: Add Roman numeral conversion to to_number
Previous Message Dmitriy Sarafannikov 2017-09-17 17:43:09 Improving DISTINCT with LooseScan node