Re: select count(*) from pg_stat_activity in V8.0.0 - Mailing list pgsql-general

From Tom Lane
Subject Re: select count(*) from pg_stat_activity in V8.0.0
Date
Msg-id 15594.1092925503@sss.pgh.pa.us
Whole thread Raw
In response to Re: select count(*) from pg_stat_activity in V8.0.0  (Richard Huxton <dev@archonet.com>)
List pgsql-general
Richard Huxton <dev@archonet.com> writes:
> Anony Mous wrote:
>> select count(*) from pg_stat_activity

> Do you have multiple live connections? My understanding of
> pg_stat_activity is that it can lag slightly behind the current state of
> the system.

If memory serves, it's up to 500 msec behind.  So this technique has
never been 100% accurate.  I'm not sure why A.Mous failed to observe the
inaccuracy before ...

            regards, tom lane

pgsql-general by date:

Previous
From: Marcel Boscher
Date:
Subject: Finally tsearch works ... somehow... remain a few questions
Next
From: Tom Lane
Date:
Subject: Re: possible bug in exception handling code? (postgres8.0beta)