Re: Logging question - Mailing list pgsql-general

From Tony Caduto
Subject Re: Logging question
Date
Msg-id 41EC7ECF.2040205@amsoftwaredesign.com
Whole thread Raw
In response to Re: Logging question  (Michael Fuhr <mike@fuhr.org>)
Responses Re: Logging question  (Michael Fuhr <mike@fuhr.org>)
List pgsql-general
Michael,
This is great info, is there a way to get the log back via a SQL call?
It would be pretty cool if there was a way to have the log go to a table
instead of a file.

Tony Caduto

Michael Fuhr wrote:

>
>ALTER USER johndoe SET log_statement TO TRUE;  -- 7.x
>ALTER USER johndoe SET log_statement TO 'all'; -- 8.0
>
>All new connections that johndoe makes will now have statement
>logging enabled.
>
>To enable logging for a particular session, execute the appropriate
>"SET log_statement" statement in that session.  If you have permission
>problems then you could wrap that operation in a function defined
>as SECURITY DEFINER and create the function as a database superuser.
>
>
>


pgsql-general by date:

Previous
From: Paul Tillotson
Date:
Subject: Re: Logging question
Next
From: William Yu
Date:
Subject: Re: ext3