Re: pg_dump -Are statistics saved?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: pg_dump -Are statistics saved?
Дата
Msg-id 4040678.1701132345@sss.pgh.pa.us
обсуждение исходный текст
Ответ на pg_dump -Are statistics saved?  (Murthy Nunna <mnunna@fnal.gov>)
Ответы Re: pg_dump -Are statistics saved?  (Laurenz Albe <laurenz.albe@cybertec.at>)
Список pgsql-admin
Murthy Nunna <mnunna@fnal.gov> writes:
> The pg_dump (used verbose) log said "pg_dump: reading extended statistics".

> Does it mean it saved statistics and they can be restored with pg_restore?

What that means is that it will output clones of any CREATE STATISTICS
commands you may have issued.

> If not, is it necessary to run ANALYZE after pg_restore?

That has always been necessary after a dump/restore, and still is.
The pg_dump man page makes this clear enough, I should think:

    The dump file produced by pg_dump does not contain the statistics used
    by the optimizer to make query planning decisions. Therefore, it is
    wise to run ANALYZE after restoring from a dump file to ensure optimal
    performance; see Section 25.1.3 and Section 25.1.6 for more
    information.

            regards, tom lane



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

Предыдущее
От: "David G. Johnston"
Дата:
Сообщение: Re: pg_dump -Are statistics saved?
Следующее
От: Nikhil Ingale
Дата:
Сообщение: idle in transaction