X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id DBA1532A3D7 for ; Thu, 30 Sep 2004 10:57:23 +0100 (BST) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 16343-02 for ; Thu, 30 Sep 2004 09:57:18 +0000 (GMT) Received: from smtp.nildram.co.uk (smtp.nildram.co.uk [195.112.4.54]) by svr1.postgresql.org (Postfix) with ESMTP id 9A37E32A3CF for ; Thu, 30 Sep 2004 10:57:19 +0100 (BST) Received: from [127.0.0.1] (tpsoft.gotadsl.co.uk [81.6.252.137]) by smtp.nildram.co.uk (Postfix) with ESMTP id 5072425D305 for ; Thu, 30 Sep 2004 10:57:16 +0100 (BST) Message-ID: <415BD807.6040103@penhey.net> Date: Thu, 30 Sep 2004 10:55:19 +0100 From: Tim Penhey User-Agent: Mozilla Thunderbird 0.8 (Windows/20040913) X-Accept-Language: en-us, en MIME-Version: 1.0 To: "pgsql-jdbc@postgresql.org" Subject: PreparedStatement.setString with null Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests=TO_ADDRESS_EQ_REAL X-Spam-Level: X-Archive-Number: 200409/208 X-Sequence-Number: 11098 What is this supposed to do? PreparedStatement stat = connection.prepareStatement("update table1 set col1 = ?"); stat.setString(1, null); Will this make a null value in the database or an empty string? Do we have to use the setNull(1, Types.VARCHAR) in order to get a null value entered? Thanks, Tim