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 33CFCD1B198 for ; Thu, 15 Jul 2004 03:02:09 -0300 (ADT) 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 03774-07 for ; Thu, 15 Jul 2004 06:02:14 +0000 (GMT) Received: from www.postgresql.com (www.postgresql.com [200.46.204.209]) by svr1.postgresql.org (Postfix) with ESMTP id 0D150D1B191 for ; Thu, 15 Jul 2004 03:02:08 -0300 (ADT) Received: from mail63.csoft.net (leary3.csoft.net [63.111.22.74]) by www.postgresql.com (Postfix) with SMTP id 09E78CF498C for ; Thu, 15 Jul 2004 03:02:12 -0300 (ADT) Received: (qmail 13433 invoked by uid 1112); 15 Jul 2004 06:02:08 -0000 Date: Thu, 15 Jul 2004 01:02:08 -0500 (EST) From: Kris Jurka X-X-Sender: books@leary.csoft.net To: "Dario V. Fassi" Cc: "pgsql-jdbc@postgresql.org" Subject: Re: Very strange Error in Updates In-Reply-To: <40F61DED.9090609@sistemat.com.ar> Message-ID: References: <40F6172D.10301@sistemat.com.ar> <40F61DED.9090609@sistemat.com.ar> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200407/172 X-Sequence-Number: 10556 On Thu, 15 Jul 2004, Dario V. Fassi wrote: > Kris Jurka wrote: > > Kris, the value of field is originate from a DB2 v6.1 with encoding > IBM-850 (Ascii PC), I don't believe that the value are unicode. I mean that java and the jdbc driver internally represent strings with unicode. If any of the data has the high bit set (ASCII values > 127) then the jdbc driver will send it as two bytes or more because it uses UTF-8. Normally the server will convert it from UTF-8 to the database's encoding, but if the database is SQL_ASCII it doesn't know how to convert it and must keep it as two bytes. You have not told us what your database's encoding is yet. Kris Jurka