Received: from localhost (maia-1.hub.org [200.46.204.191]) by postgresql.org (Postfix) with ESMTP id 97F4E9FA434 for ; Fri, 2 Mar 2007 04:22:58 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.191]) (amavisd-new, port 10024) with ESMTP id 39106-04 for ; Fri, 2 Mar 2007 04:22:56 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from floppy.pyrenet.fr (news.pyrenet.fr [194.116.145.2]) by postgresql.org (Postfix) with ESMTP id 8DD5B9FA320 for ; Fri, 2 Mar 2007 04:22:55 -0400 (AST) Received: by floppy.pyrenet.fr (Postfix, from userid 106) id 17CF1308E7; Fri, 2 Mar 2007 09:22:52 +0100 (MET) From: aaabdallah@gmail.com X-Newsgroups: pgsql.interfaces.jdbc Subject: Re: Inserting "null" not working (Sun App Server, Postgres, EJB3)? Date: 2 Mar 2007 00:22:44 -0800 Organization: http://groups.google.com Lines: 21 Message-ID: <1172823764.106772.94010@v33g2000cwv.googlegroups.com> References: <40939ed60703010604j149caad2n92dccac2ae6f6824@mail.gmail.com> <3AC75FD4-F9DC-4B9E-AA60-38F67EFD39B0@redhat.com> <0DC8A2E6-BB3C-4592-BF9E-7EECA0CCE37B@fastcrypt.com> <23779.1172793964@sss.pgh.pa.us> <26671.1172794578@sss.pgh.pa.us> <9412284C-E14A-4A9E-97C6-F2680457E08F@fastcrypt.com> <630396DA-4BD3-48B2-8504-78F555BAC5FF@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Complaints-To: groups-abuse@google.com In-Reply-To: <630396DA-4BD3-48B2-8504-78F555BAC5FF@redhat.com> User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.2) Gecko/20070219 Firefox/2.0.0.2,gzip(gfe),gzip(gfe) Complaints-To: groups-abuse@google.com Injection-Info: v33g2000cwv.googlegroups.com; posting-host=87.109.228.115; posting-account=tA0DEw0AAADxMt9b4vENDbOfN8Kw2uG_ To: pgsql-jdbc@postgresql.org X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.962 tagged_above=0 required=5 tests=BAYES_50, NO_REAL_NAME X-Spam-Level: X-Archive-Number: 200703/17 X-Sequence-Number: 16731 Wait, Heiko, I hope you get this message before you spend your time on this! First of all, I confirmed what Dave said: the Oracle Toplink package was indeed sending every single NULL with an SQL type of VARCHAR. I downloaded the postgresql JDBC source code and slowly traced what was going on, and put in the necessary printlns to see what was being sent. Garbage in, garbage out. The good news: the latest version of the Toplink package solves it: it correctly switches the type of the NULL based on the real type of the field. I thank you very much for attempting to help me, and I hope your problem also gets solved similarly thru an upgrade. It is frustrating building off of buggy software, but on the other hand, these are enormously useful packages that people are putting out for free, so I can't complain. Just gotta try and get some uninterrupted sleep now... -A