Skip site navigation (1) Skip section navigation (2)

Re: [PATCHES] Approximate count(*)

From: "Greg Sabino Mullane" <greg(at)turnstep(dot)com>
To: pgsql-docs(at)postgresql(dot)org
Subject: Re: [PATCHES] Approximate count(*)
Date: 2005-03-25 02:34:14
Message-ID: 125db1c7753893171b6ef46609035de8@biglumber.com (view raw or flat)
Thread:
Lists: pgsql-docspgsql-patches
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

  
David Fetter wrote:
> Please find enclosed a patch that shows how to get a quick
> approximation of count(*) on a table.
  
You should mention that ANALYZE will also populate reltuples.
  
To be real anal, you should say pg_catalog.pg_class too. :)
  
Tom Lane asked:
>> I'm not sure we should be encouraging people to look at reltuples...
>> for one thing, it's deliberately a moving average under 8.0.
  
> Should there be more caveats?
  
Well, it already says "approximate", the value-laden word is "good".
Perhaps if that went away...

- --
Greg Sabino Mullane greg(at)turnstep(dot)com
PGP Key: 0x14964AC8 200503242126
http://biglumber.com/x/web?pk=2529DF6AB8F79407E94445B4BC9B906714964AC8
-----BEGIN PGP SIGNATURE-----

iD8DBQFCQ3iivJuQZxSWSsgRAm+PAKCNJPUl7Xns0kLKvbDjOiuNN2g4agCfbmg+
hX8RHO4R2Ad2fQyCPl+Ha3I=
=2Gal
-----END PGP SIGNATURE-----



In response to

Responses

pgsql-docs by date

Next:From: Josh BerkusDate: 2005-03-25 03:19:00
Subject: Re: [PATCHES] Approximate count(*)
Previous:From: David FetterDate: 2005-03-24 17:58:27
Subject: Re: [PATCHES] Approximate count(*)

pgsql-patches by date

Next:From: Bruce MomjianDate: 2005-03-25 02:57:54
Subject: Re: Makefile breakage
Previous:From: Bruce MomjianDate: 2005-03-25 01:01:39
Subject: Re: pgsql: Add URL of how to report bugs:

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group