X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 16189D6F8F for ; Tue, 23 Aug 2005 11:46:50 -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 81565-09 for ; Tue, 23 Aug 2005 14:46:48 +0000 (GMT) Received: from obelix.askesis.nl (laudanum.demon.nl [82.161.125.16]) by svr1.postgresql.org (Postfix) with ESMTP id 3675BD6E84 for ; Tue, 23 Aug 2005 11:46:46 -0300 (ADT) Received: obelix.askesis.nl 172.31.0.1 from 172.31.1.8 172.31.1.8 via HTTP with MS-WebStorage 6.0.6249 Received: from Panoramix by obelix.askesis.nl; 23 Aug 2005 16:46:50 +0200 Subject: Re: Is this error correct/possible? From: Joost Kraaijeveld To: Marc Herbert Cc: "pgsql-jdbc@postgresql.org" In-Reply-To: <87slx0n51e.fsf@meije.emic.fr> References: <1124790915.27046.25.camel@panoramix.askesis.nl> <87slx0n51e.fsf@meije.emic.fr> Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Date: Tue, 23 Aug 2005 16:46:50 +0200 Message-Id: <1124808410.27046.49.camel@panoramix.askesis.nl> Mime-Version: 1.0 X-Mailer: Evolution 2.0.4 X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.099 required=5 tests=[AWL=0.049, FORGED_RCVD_HELO=0.05] X-Spam-Level: X-Archive-Number: 200508/173 X-Sequence-Number: 13742 On Tue, 2005-08-23 at 15:42 +0200, Marc Herbert wrote: > Could you copy/paste the complete exception and stacktrace? Invalid character data was found. This is most likely caused by stored dat= a containing characters that are invalid for the character set the database= was created in. The most common example of this is storing 8bit data in a= SQL_ASCII database. org.postgresql.util.PSQLException: Invalid character data was found. This is most likely caused by stored data containing characters that are invalid for the character set the database was created in. The most common example of this is storing 8bit data in a SQL_ASCII database. at org.postgresql.jdbc2.AbstractJdbc2ResultSet.getString(AbstractJdbc2ResultSe= t.java:1904) at org.postgresql.jdbc2.AbstractJdbc2ResultSet.getString(AbstractJdbc2ResultSe= t.java:2203) at nl.muntpost.MuntpostApp.main(MuntpostApp.java:42) Caused by: java.io.IOException: UTF-8 string representation was truncated at org.postgresql.core.Encoding.decodeUTF8(Encoding.java:304) at org.postgresql.core.Encoding.decode(Encoding.java:179) at org.postgresql.core.Encoding.decode(Encoding.java:193) at org.postgresql.jdbc2.AbstractJdbc2ResultSet.getString(AbstractJdbc2ResultSe= t.java:1900) ... 2 more > > Inspection of the row (using pgadmin3) shows that there is the char "= =FC" > > in a char(40) columns. > > > > Questions: > > > > 1. Is a "=FC" allowed in a SQL_ASCII database and a column of char(40)? >=20 > From a very recent discussion on pgsql-Odbc (check the archive), it is > not allowed. Not allowed "anymore" from what I got. Which is quite > sensible considering that =FC is not ASCII: how would you sort it, upper > it, etc.? I did not get if this has been recently enforced by the ODBC > driver, the engine, both... check the archive. OK, this is what I expected.=20 >=20 > > 2. If so, is this a JDBC bug? >=20 > The stacktrace and such debug stuff would help tracking what JDBC is > doing here. See above. >=20 > > 3. If not, is this a PostgreSQL bug, allowing a non-allowed character i= n > > a column? >=20 > Maybe it was allowed in 747, not anymore in 8.0.3 ? From another mail I understood that is this is just the way it is.=20 Joost