Re: Getting statistics for each sql statement?

From: Ben Chobot <bench(at)silentmedia(dot)com>
To: s(dot)guenther(at)in-put(dot)de
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Getting statistics for each sql statement?
Date: 2010-07-22 14:48:43
Message-ID: 078E95C6-CF2D-4849-B2D1-26E7A39B3F4D@silentmedia.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Jul 22, 2010, at 4:50 AM, Stefan-Michael Guenther wrote:

> Hello,
>
> is it possible to get statistics on the usage of different sql statements, e.g. how many INSERT or UPDATE statements per day?
>
> log_statement_stats doesn't seem to be the right parameter or I haven't found the output statistic for this command.
>
> Any ideas or suggestions?

The usual approach is to make a log file that holds all your queries and then let something like pgFouine grovel through it.

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Armand Turpel 2010-07-22 15:38:14 varchar[] or text[]
Previous Message Matthew Wilson 2010-07-22 14:45:45 How to improve performance in reporting database?