Re: *sigh*

From: Shridhar Daithankar <shridhar_daithankar(at)myrealbox(dot)com>
To: Mark Kirkwood <markir(at)paradise(dot)net(dot)nz>, Christopher Browne <cbbrowne(at)acm(dot)org>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: *sigh*
Date: 2003-12-03 09:16:30
Message-ID: 200312031446.30141.shridhar_daithankar@myrealbox.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wednesday 03 December 2003 13:59, Mark Kirkwood wrote:
> How about:
>
> Implement a function "estimated_count" that can be used instead of
> "count". It could use something like the algorithm in
> src/backend/commands/analyze.c to get a reasonably accurate psuedo count
> quickly.
>
> The advantage of this approach is that "count" still means (exact)count
> (for your xact snapshot anyway). Then the situation becomes:
>
> Want a fast count? - use estimated_count(*)
> Want an exact count - use count(*)

Something like select reltuples from pg_class where relname='foo'?

Shridhar

In response to

  • Re: *sigh* at 2003-12-03 08:29:08 from Mark Kirkwood

Responses

  • Re: *sigh* at 2003-12-06 11:40:54 from Mark Kirkwood

Browse pgsql-hackers by date

  From Date Subject
Next Message Randolf Richardson 2003-12-03 10:20:23 Re: ISO 8601 'Time Intervals' of the 'format with time-unit deignators'
Previous Message Richard Huxton 2003-12-03 09:03:30 Re: Transaction Question