X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 8D1C2D1E5C7 for ; Sun, 23 May 2004 03:59:42 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 06463-07 for ; Sun, 23 May 2004 03:59:21 -0300 (ADT) Received: from www.postgresql.com (www.postgresql.com [200.46.204.209]) by svr1.postgresql.org (Postfix) with ESMTP id D9007D1ED0D for ; Sun, 23 May 2004 03:05:22 -0300 (ADT) Received: from yass.opencloud.co.nz (yass.opencloud.co.nz [203.79.85.162]) by www.postgresql.com (Postfix) with ESMTP id A8341CF8A9D for ; Sat, 22 May 2004 20:59:08 -0300 (ADT) Received: from 203-79-104-60.cable.paradise.net.nz ([203.79.104.60] helo=opencloud.com) by yass.opencloud.co.nz with asmtp (Exim 3.35 #1 (Debian)) id 1BRgOU-0001hf-00 for ; Sun, 23 May 2004 11:59:10 +1200 Message-ID: <40AFE94B.7060904@opencloud.com> Date: Sun, 23 May 2004 11:59:07 +1200 From: Oliver Jowett User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6b) Gecko/20031205 Thunderbird/0.4 X-Accept-Language: en-us, en MIME-Version: 1.0 To: "pgsql-jdbc@postgresql.org" Subject: PreparedStatement & direct execution methods Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at postgresql.org X-Spam-Status: No, hits=0.1 tagged_above=0.0 required=5.0 tests=RCVD_IN_SORBS, TO_ADDRESS_EQ_REAL X-Spam-Level: X-Archive-Number: 200405/154 X-Sequence-Number: 10164 Just noticed this in the JDBC spec (13.2.4): If any of the PreparedStatement execute methods is called with an SQL string as a parameter, an SQLException is thrown. (don't you love how you have to look at both the spec and the javadoc to discover the behaviour of particular methods?) The current driver doesn't do this, and we've had at least one bug report that turned out to be caused by calling an execute...() method with a string on a PreparedStatement. Worth fixing? -O