Re: Improving N-Distinct estimation by ANALYZE - Mailing list pgsql-hackers

From Josh Berkus
Subject Re: Improving N-Distinct estimation by ANALYZE
Date
Msg-id 43BCBD27.5080002@agliodbs.com
Whole thread Raw
In response to Re: Improving N-Distinct estimation by ANALYZE  (Josh Berkus <josh@agliodbs.com>)
List pgsql-hackers
Folks,

> Nope, it's definitely proportional.   As a simple example, a sample of 
> 500 rows in a table of 1000 rows should yeild stats estimates with 90%+ 
> accuracy.  But a sample of 500 rows in a 600,000,000 row table is so 
> small as to be nearly useless; it's quite possible to get all the same 
> value in a random sample of < 0.1% even on a column with a D/N of 0.001. 

I meant "a D/N of 0.1".  Sorry.

--Josh


pgsql-hackers by date:

Previous
From: Josh Berkus
Date:
Subject: Re: Improving N-Distinct estimation by ANALYZE
Next
From: Simon Riggs
Date:
Subject: Re: Improving N-Distinct estimation by ANALYZE