Re: Statistics Import and Export

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Statistics Import and Export
Дата
Msg-id 1816936.1747942867@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Statistics Import and Export  (Greg Sabino Mullane <htamfids@gmail.com>)
Список pgsql-hackers
Greg Sabino Mullane <htamfids@gmail.com> writes:
> On Thu, May 22, 2025 at 2:52 PM Jeff Davis <pgsql@j-davis.com> wrote:
>> * The default for pg_restore is --no-statistics. That could cause a minor
>> surprise if the user specifies --with-statistics for pg_dump and
>> not for pg_restore.

> Hm...somewhat to my own surprise, I don't like this. If it's in the dump,
> restore it.

Yeah, I tend to lean that way too.  If the user went out of their way
to say --with-statistics for pg_dump, how likely is it that they
don't want the statistics restored?

Another argument pointing in that direction is that the definition
Jeff proposes creates an inconsistency in the output between text
mode:

    pg_dump --with-statistics ... | psql

and non-text mode:

    pg_dump -Fc --with-statistics ... | pg_restore

There is no additional filter in text mode, so I think pg_restore's
default behavior should also be "no additional filter".

            regards, tom lane



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