From: Aaron Held <aaron@MetroNY.com>
To: Bruce Momjian <pgman@candle.pha.pa.us>
Cc: Neil Conway <neilc@samurai.com>
Cc: pgsql-sql@postgresql.org
Cc: pgsql-general@postgresql.org
Subject: Re: Monitoring a Query
Date: Mon, 23 Sep 2002 09:24:38 -0400
Message-ID: <3D8F1616.3040509@MetroNY.com> (raw)
References: <200209230151.g8N1ptW22413@candle.pha.pa.us>
Bruce Momjian wrote:
> Neil Conway wrote:
>
>>Bruce Momjian <pgman@candle.pha.pa.us> writes:
>>
>>>Aaron Held wrote:
>>>
>>>>Is there any way to monitor a long running query?
>>>
>>>Oh, sorry, you want to know how far the query has progressed. Gee, I
>>>don't think there is any easy way to do that.
>>
>>Would it be a good idea to add the time that the current query began
>>execution at to pg_stat_activity?
>
>
> What do people think about this? It seems like a good idea to me.
>
My application marks the start time of each query and I have found it
very useful. The users like to see how long each query took, and the
admin can take a quick look and see how many queries are running and how
long each has been active for. Good for debugging and billing.
-Aaron Held
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: aaron@MetroNY.com, pgman@candle.pha.pa.us, neilc@samurai.com, pgsql-general@postgresql.org
Subject: Re: Monitoring a Query
In-Reply-To: <3D8F1616.3040509@MetroNY.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox