Re: estimating # of distinct values - Mailing list pgsql-hackers

From Tom Lane
Subject Re: estimating # of distinct values
Date
Msg-id 7214.1293490512@sss.pgh.pa.us
Whole thread Raw
In response to Re: estimating # of distinct values  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
Responses Re: estimating # of distinct values  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
List pgsql-hackers
"Kevin Grittner" <Kevin.Grittner@wicourts.gov> writes:
> Robert Haas <robertmhaas@gmail.com> wrote:
>> With respect to (b), I think I'd need to see a much more detailed
>> design for how you intend to make this work.  Off the top of my
>> head there seems to be some pretty serious feasibility problems.
> I had one random thought on that -- it seemed like a large concern
> was that there would need to be at least an occasional scan of the
> entire table to rebuild the distinct value information.  Don't we
> already require an occasional scan of the entire table for freezing
> transaction IDs?  Could this be part of any vacuum of the entire
> table?

Well, first, those scans occur only once every few hundred million
transactions, which is not likely a suitable timescale for maintaining
statistics.  And second, we keep on having discussions about rejiggering
the whole tuple-freezing strategy.  Even if piggybacking on those scans
looked useful, it'd be unwise to assume it'll continue to work the same
way it does now.
        regards, tom lane


pgsql-hackers by date:

Previous
From: "Kevin Grittner"
Date:
Subject: Re: estimating # of distinct values
Next
From: "Kevin Grittner"
Date:
Subject: Re: estimating # of distinct values