Re: Multivariate MCV list vs. statistics target - Mailing list pgsql-hackers

From Tomas Vondra
Subject Re: Multivariate MCV list vs. statistics target
Date
Msg-id 20190708181814.z7nrb32qrbhitgs6@development
Whole thread Raw
In response to Re: Multivariate MCV list vs. statistics target  (Tomas Vondra <tomas.vondra@2ndquadrant.com>)
Responses RE: Multivariate MCV list vs. statistics target
List pgsql-hackers
On Sun, Jul 07, 2019 at 12:02:38AM +0200, Tomas Vondra wrote:
>Hi,
>
>apparently v1 of the ALTER STATISTICS patch was a bit confused about
>length of the VacAttrStats array passed to statext_compute_stattarget,
>causing segfaults. Attached v2 patch fixes that, and it also makes sure
>we print warnings about ignored statistics only once.
>

v3 of the patch, adding pg_dump support - it works just like when you
tweak statistics target for a column, for example. When the value stored
in the catalog is not -1, pg_dump emits a separate ALTER STATISTICS
command setting it (for the already created statistics object).

I've considered making it part of CREATE STATISTICS itself, but it seems
a bit cumbersome and we don't do it for columns either. I'm not against
adding it in the future, but at this point I don't see a need.

At this point I'm not aware of any missing or broken pieces, so I'd
welcome feedback.

regards

--
Tomas Vondra                  http://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Attachment

pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: progress report for ANALYZE
Next
From: Alvaro Herrera
Date:
Subject: Re: progress report for ANALYZE