Re: Odd statistics behaviour in 7.2

From: Thomas Lockhart <lockhart(at)fourpalms(dot)org>
To: "Gordon A(dot) Runkle" <gar(at)integrated-dynamics(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Odd statistics behaviour in 7.2
Date: 2002-02-13 14:41:34
Message-ID: 3C6A7B1E.EE0BEF92@fourpalms.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> ... sometimes ... 'n_distinct' for this column
> gets a value of '-1' (desireable), and other times a value such as 56596
> or something.
> This is with the default setting for the statistics.
> Doing a 'SET STATISTICS 40' on the column got me to '-0.106047', which
> is better. But even so, the values do change somewhat over subsequent
> runs of VACUUM ANALYZE. And sometimes I get the coveted '-1'.

I'm guessing that your table is not randomly populated, so that the new
"statistically sampled ANALYZE" is sometimes getting a good sample (or
at least one with the result you want) and sometimes getting a terrible
one.

Tom?

- Thomas

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Doug McNaught 2002-02-13 14:42:57 Re: Connection Pooling
Previous Message Marc G. Fournier 2002-02-13 13:53:43 "Bug" in statistics for v7.2?