Re: Odd statistics behaviour in 7.2 - Mailing list pgsql-hackers

From Gordon A. Runkle
Subject Re: Odd statistics behaviour in 7.2
Date
Msg-id 1013840193.21153.213.camel@spiff.runkleinc.com
Whole thread Raw
In response to Re: Odd statistics behaviour in 7.2  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Odd statistics behaviour in 7.2  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: Odd statistics behaviour in 7.2  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On Fri, 2002-02-15 at 19:09, Tom Lane wrote:
> "Gordon A. Runkle" <gar@integrated-dynamics.com> writes:
> > [ tale of poor statistical results in a near-unique column ]
> [ new algorithm and patch ]

Hi Tom,

This works much better (I did SET STATISTICS back to 10).  Not always
'-1', but almost always negative.

Is "-0.503824" the same as "503824 with a predicted increase in the
number of distinct values" (as opposed to using "-503824")?

I checked a couple of other tables for which my field is a bit less
nearly-unique, and they have better stats now also.  I've attached a
file with distributions and stats, if you're interested.

And, getting to where the rubber meets the road, my queries are running
well again!

I'm running a batch of other queries (which were unaffected by this
problem) overnight to see if they still work well.

Are you planning to include this patch in v7.2.1, or would it require
too much testing by others?

Thanks for all your hard work, it is greatly appreciated,

Gordon.
--
"Far and away the best prize that life has to offer
  is the chance to work hard at work worth doing."
       -- Theodore Roosevelt


Attachment

pgsql-hackers by date:

Previous
From: Lamar Owen
Date:
Subject: Re: Maintaining the list of release changes
Next
From: Oliver Elphick
Date:
Subject: pg_ctl - tighten command parameter checking