Обсуждение: Is there any way to force analyze to run on a whole table?

Поиск
Список
Период
Сортировка

Is there any way to force analyze to run on a whole table?

От
Joseph Shraibman
Дата:
Is there any way to force analyze to run on a whole table?  In other words for large
tables to avoid sampling?  What happens if I run a vacuum analyze?


Re: Is there any way to force analyze to run on a whole table?

От
Tom Lane
Дата:
Joseph Shraibman <jks@selectacast.net> writes:
> Is there any way to force analyze to run on a whole table?

No.  IIRC the sample size is 300 * <largest column statistic setting>,
so at most 300k rows.  In the current implementation, ANALYZE will
actually suck the entire sample into memory, so you really really don't
want it trying to analyze millions of rows anyway...

            regards, tom lane