pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Brett W. McCoy <bmccoy@chapelperilous.net>
To: Duncan Adams (DNS) <duncan.adams@vcontractor.co.za>
Cc: Pgsql Novice <pgsql-novice@postgresql.org>
Subject: Re: Logging
Date: Fri, 30 Nov 2001 10:04:44 -0500 (EST)
Message-ID: <Pine.LNX.4.30.0111301002080.3357-100000@chapelperilous.net> (raw)
In-Reply-To: <C54EF5B83335D311BCB50000C11042B102C8C797@vodabemail1.vodacom.co.za>

On Fri, 30 Nov 2001, Duncan Adams  (DNS) wrote:

> I was wondering if there is any way to track/log what sql commands have been
> send to the postgres database from an external source. For example, from a
> PHP/pearl script.

Yes, there is.  I believe if you set DEBUG_PRINT_QUERY in postgresql.conf,
it will log the queries.

See http://www.postgresql.org/idocs/index.php?runtime-config.html#LOGGING
for more details.

-- Brett
                                          http://www.chapelperilous.net/
------------------------------------------------------------------------
The turtle lives 'twixt plated decks
Which practically conceal its sex.
I think it clever of the turtle
In such a fix to be so fertile.
		-- Ogden Nash




view thread (4+ messages)

Message-ID: <Pine.LNX.4.30.0111301002080.3357-100000@chapelperilous.net>
Permalink:  ../Pine.LNX.4.30.0111301002080.3357-100000@chapelperilous.net/
Also on:    postgresql.org/message-id/Pine.LNX.4.30.0111301002080.3357-100000@chapelperilous.net

 · 

reply

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: bmccoy@chapelperilous.net, duncan.adams@vcontractor.co.za, pgsql-novice@postgresql.org
  Subject: Re: Logging
  In-Reply-To: <Pine.LNX.4.30.0111301002080.3357-100000@chapelperilous.net>
  References: <C54EF5B83335D311BCB50000C11042B102C8C797@vodabemail1.vodacom.co.za> <Pine.LNX.4.30.0111301002080.3357-100000@chapelperilous.net>

* 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