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 26CA29DC86C for ; Mon, 19 Dec 2005 15:04:06 -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 21121-06 for ; Mon, 19 Dec 2005 15:04:05 -0400 (AST) X-Greylist: delayed 00:06:36.627749 by SQLgrey- Received: from web32010.mail.mud.yahoo.com (web32010.mail.mud.yahoo.com [68.142.207.107]) by postgresql.org (Postfix) with SMTP id 6FF389DC810 for ; Mon, 19 Dec 2005 15:04:02 -0400 (AST) Received: (qmail 47642 invoked by uid 60001); 19 Dec 2005 18:57:23 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:Received:Date:From:Subject:To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=NA3LRoZxw2O85t/y8BFowh6Q/C6QK5pRDO78BsqDTOFzV5iBi+NGeNvP5ZoaZqYUL983nD4idAgW4z3PchyehxtBIDq6MY7NC2Vv98f+EelcA0+sNms4yooKZQgzF6SwqCpeZ1HYIWmYv6z8FrG16ZL6cJWlkkSaED5DwbGhDnA= ; Message-ID: <20051219185723.47640.qmail@web32010.mail.mud.yahoo.com> Received: from [165.123.243.168] by web32010.mail.mud.yahoo.com via HTTP; Mon, 19 Dec 2005 10:57:23 PST Date: Mon, 19 Dec 2005 10:57:23 -0800 (PST) From: "j.random.programmer" Subject: 8.2dev-500.jdbc3 driver: PreparedStatement.toString() is buggy To: pgsql-jdbc@postgresql.org MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.479 required=5 tests=[DNS_FROM_RFC_ABUSE=0.479] X-Spam-Score: 0.479 X-Spam-Level: X-Archive-Number: 200512/81 X-Sequence-Number: 14412 Hi: There seems to be a bug with the 8.2dev-500 driver, running against a postgres 8.1 database. If I have a PreparedStatement, then when I say: System.out.println(ps) the the prepared statement that is printed is *missing* single quotes around data/time AND character/string values. This means that I cannot copy that preparedstatment and paste it directly into a psql session etc. For example, this is what a ps.toString() looks like: -------------------------------------- INSERT into alltypes (smallint_val, int_val, bigint_val, float_val, double_val, numeric_val, char_val, varchar_val, timestamp_val, bit_val, varbinary_val) values (5, 6, 7000, 3.14, 3.141, 11.32, foo2, bar2, 2005-12-19 09:55:23.464000 -0500, 1, ) ------------------------------------- Note, this is not valid sql since no quotes around 'foo2', 'bar2', '2005...' etc (which are respectively char and date types). This is definitely a regression, this did not happen with earlier drivers. Best regards, --j __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com