X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 310E19DCA7E for ; Mon, 27 Mar 2006 23:01:31 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 53518-09 for ; Mon, 27 Mar 2006 23:01:35 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from net2.micro-automation.com (net2.micro-automation.com [64.7.141.29]) by postgresql.org (Postfix) with SMTP id C3AF99DC85E for ; Mon, 27 Mar 2006 23:01:23 -0400 (AST) Received: (qmail 3046 invoked from network); 28 Mar 2006 03:01:28 -0000 Received: from dcdsl.ebox.com (HELO ?192.168.1.2?) (davec@64.7.143.116) by net2.micro-automation.com with SMTP; 28 Mar 2006 03:01:28 -0000 In-Reply-To: <442890D9.40905@catalyst.net.nz> References: <442890D9.40905@catalyst.net.nz> Mime-Version: 1.0 (Apple Message framework v746.3) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: Cc: pgsql-jdbc@postgresql.org Content-Transfer-Encoding: 7bit From: Dave Cramer Subject: Re: Printing query durations Date: Mon, 27 Mar 2006 22:01:26 -0500 To: Kevin Dorne X-Mailer: Apple Mail (2.746.3) X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.134 required=5 tests=[AWL=0.134] X-Spam-Score: 0.134 X-Spam-Level: X-Archive-Number: 200603/120 X-Sequence-Number: 14901 Kevin, There is no difference between a jdbc query and a psql query. The backend doesn't know where the query comes from. DAve On 27-Mar-06, at 8:26 PM, Kevin Dorne wrote: > Hello, > > I am having some trouble getting PostgreSQL to log durations with > statements when called through JDBC. They appear just fine with > interactive queries using psql, but the duration field does not > show up > on JDBC queries. > > Is there some configuration I need to pass to the JDBC driver? > > Example output from an interactive query: > LOG: duration: 109.524 ms statement: SELECT count(*) FROM > transaction; > > Example output from a JDBC query: > LOG: statement: SELECT count(*) FROM transaction; > > Cheers, > -k >