Re: MCV lists for highly skewed distributions - Mailing list pgsql-hackers

From Dean Rasheed
Subject Re: MCV lists for highly skewed distributions
Date
Msg-id CAEZATCVwr4yH=9r-H8mtAtLxXGeREqEtGVJDA9iLOaHY9PYCDg@mail.gmail.com
Whole thread Raw
In response to Re: MCV lists for highly skewed distributions  (Robert Haas <robertmhaas@gmail.com>)
List pgsql-hackers
On 1 February 2018 at 17:49, Robert Haas <robertmhaas@gmail.com> wrote:
> One point which I want to emphasize is that the length of the MCV list
> bounds the estimated frequency of non-MCVs in two ways: no non-MCV is
> ever thought to be more frequent than the least-common MCVs, and
> however many non-MCVs we think we have (probably fewer than we
> actually have) have to fit into whatever percentage of the table is
> consumed by MCVs.  This would be less important if we had reliable
> n_distinct estimates, but we don't.  So, even throwing things into the
> MCV list that are no more common than the average item can improve
> planning in some cases.
>

That's a good point, and a nice explanation. I think that lends more
weight to the argument that we should be including as many MCVs as
possible, provided there's enough evidence to justify their inclusion.

Regards,
Dean


pgsql-hackers by date:

Previous
From: amul sul
Date:
Subject: Re: [HACKERS] Restrict concurrent update/delete with UPDATE ofpartition key
Next
From: Ashutosh Bapat
Date:
Subject: Re: [HACKERS] path toward faster partition pruning