Re: Merging statistics from children instead of re-sampling everything

Поиск
Список
Период
Сортировка
От Justin Pryzby
Тема Re: Merging statistics from children instead of re-sampling everything
Дата
Msg-id 20210329183624.GC4431@telsasoft.com
обсуждение исходный текст
Ответ на Merging statistics from children instead of re-sampling everything  (Tomas Vondra <tomas.vondra@enterprisedb.com>)
Ответы Re: Merging statistics from children instead of re-sampling everything  (Tomas Vondra <tomas.vondra@enterprisedb.com>)
Список pgsql-hackers
Thanks for taking a fresh look at this.

As you've written it, this can apply to either/both partitioned or inheritence.
I imagine when "MERGE" goes away, this should apply only to partitioned tables.
(Actually, personally I would advocate to consider applying it to *both*, but I
don't think that's been the tendency over the last 4 years.  I wrote here about
some arguably-gratuitous differences between inheritence and partitioning.
https://www.postgresql.org/message-id/20180601221428.GU5164@telsasoft.com)

> +     if (*mcv_items > default_statistics_target)
> +             n = default_statistics_target;

It should use any non-default stats target of the parent's column

> +         * ignore anything but valid leaf relatiins with data, but release

sp: relatiins.

> +                elog(WARNING, "stats for %d %d not found",
> +                                        RelationGetRelid(rels[j]), vacattrstats[i]->attr->attnum);

should be %u %d

This code duplication is undesirable:
> +    /* Log the action if appropriate */
> +     * Determine which columns to analyze



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Cary Huang
Дата:
Сообщение: Re: [PATCH] Add --create-only option to pg_dump/pg_dumpall
Следующее
От: Fujii Masao
Дата:
Сообщение: Re: TRUNCATE on foreign table