Received: from klamath.dyndns.org (CPE002078144ae0.cpe.net.cable.rogers.com [24.102.202.35]) by postgresql.org (Postfix) with ESMTP id C7C7F47552B for ; Tue, 30 Jul 2002 10:12:03 -0400 (EDT) Received: by klamath.dyndns.org (Postfix, from userid 1000) id 10436700C; Tue, 30 Jul 2002 10:12:08 -0400 (EDT) Date: Tue, 30 Jul 2002 10:12:08 -0400 To: Bruce Momjian Cc: Andrew Sullivan , pgsql-general@postgresql.org Subject: Re: log sql? Message-ID: <20020730141207.GB13322@klamath.dyndns.org> Mail-Followup-To: Bruce Momjian , Andrew Sullivan , pgsql-general@postgresql.org References: <20020729084413.A8252@mail.libertyrms.com> <200207300414.g6U4EGI29236@candle.pha.pa.us> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200207300414.g6U4EGI29236@candle.pha.pa.us> User-Agent: Mutt/1.4i From: nconway@klamath.dyndns.org (Neil Conway) X-Archive-Number: 200207/1796 X-Sequence-Number: 28282 On Tue, Jul 30, 2002 at 12:14:16AM -0400, Bruce Momjian wrote: > Andrew Sullivan wrote: > > On Fri, Jul 26, 2002 at 03:27:45PM -0700, Laurette Cisneros wrote: > > > > > > Is there way to track each sql statement and the user for the server? > > > > Sort of. Turn on query logging in the postgresql.conf file, and also > > log connections and PID. Then, you can track back by using the PID, > > to discovere who logged in (and therefore, who issued that query). > > Andrew, what postgresql.conf parameter is query logging. debug_print_query Cheers, Neil -- Neil Conway PGP Key ID: DB3C29FC