pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Scott Marlowe <scott.marlowe@gmail.com>
Cc: Rajesh Kumar Mallah <mallah.rajesh@gmail.com>
Cc: Achilleas Mantzios <achill@matrix.gatewaynet.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: conditional logging based on client
Date: Wed, 23 Jul 2008 15:12:03 -0400
Message-ID: <3289.1216840323@sss.pgh.pa.us> (raw)
In-Reply-To: <dcc563d10807231022g24d7e5e7v6636da3fc458583a@mail.gmail.com>
References: <a97c77030807220517u2324a0cckb8400a359123426a@mail.gmail.com>
	<200807221524.45181.achill@matrix.gatewaynet.com>
	<a97c77030807221040n4a791582tb098b0ba9c54944c@mail.gmail.com>
	<dcc563d10807231022g24d7e5e7v6636da3fc458583a@mail.gmail.com>

"Scott Marlowe" <scott.marlowe@gmail.com> writes:
> 2008/7/22 Rajesh Kumar Mallah <mallah.rajesh@gmail.com>:
>> any hit on performance is not desired.
>> is it possible to alter logging behaviour just for the
>> psql session ?

> Set log_statement='ddl' in your postgresql.conf and pgsql will log all
> ddl that hits the database.  It won't log other stuff, just the ddl.

I think the OP didn't want *all* sessions doing this but just selected
sessions; so ALTER USER ... SET log_statement, or possibly
ALTER DATABASE ... SET, would perhaps serve better.

			regards, tom lane



view thread (7+ messages)

Message-ID: <3289.1216840323@sss.pgh.pa.us>
Permalink:  ../3289.1216840323@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/3289.1216840323@sss.pgh.pa.us

 · 

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 using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: tgl@sss.pgh.pa.us, scott.marlowe@gmail.com, mallah.rajesh@gmail.com, achill@matrix.gatewaynet.com
  Subject: Re: conditional logging based on client
  In-Reply-To: <3289.1216840323@sss.pgh.pa.us>

* 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