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 DA0573A4641 for ; Wed, 27 Oct 2004 14:23:37 +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 43677-03 for ; Wed, 27 Oct 2004 13:23:29 +0000 (GMT) Received: from paul.nmi.northlandministries.org (paul.nmi.northlandministries.org [65.160.35.6]) by svr1.postgresql.org (Postfix) with ESMTP id 810903A3CBA for ; Wed, 27 Oct 2004 14:23:29 +0100 (BST) X-MimeOLE: Produced By Microsoft Exchange V6.0.6487.1 content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Subject: Re: using 8 bit ascii Date: Wed, 27 Oct 2004 08:23:29 -0500 Message-ID: <04875CB4331F0240A0AD66F97097865101137ADD@paul> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: [JDBC] using 8 bit ascii Thread-Index: AcS8J27q+GMAqQCBSP+ewrlNihhRfAAAEcwQ From: "Jason Tesser" To: "Anders Hermansen" , 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: 200410/277 X-Sequence-Number: 11382 OK I tried the Unicode but the data won't come in as it says it cannot supp= ort the Unicode values I am inserting. I tried converting the data as a te= xt file and everything. Nothing has worked there. With odbc using access = for example I can pull the 8 bit characters out just fine from the same dat= abase. So why can I not using postgres jdbc? I understand that ascii is 7 bit but these are extended ascii. I will try = Latin 1 > -----Original Message----- > From: pgsql-jdbc-owner@postgresql.org [mailto:pgsql-jdbc- > owner@postgresql.org] On Behalf Of Anders Hermansen > Sent: Wednesday, October 27, 2004 8:12 AM > To: pgsql-jdbc@postgresql.org > Subject: Re: [JDBC] using 8 bit ascii >=20 > Hello Jason, >=20 > ASCII is only 7-bit. Values 0 to 127. >=20 > ISO-8859-1 is an example of a character set with 8-bits (0 to 255). > 233 is =E9 in ISO-8859-1 (Latin-1). >=20 > You should create the database with an encoding which can handle 8-bit > characters. I.e. ISO-8859-1 (Postgresql: Latin-1) or UTF-8 (Postgresql: > UNICODE) >=20 >=20 > Anders >=20 > * Jason Tesser (JTesser@nbbc.edu) wrote: > > I have a Postgres database (version 7.4.2) that is using acsii character > > 233 which is an 8 > > bit ascii character. I also use jboss. My problem is when I try to > > retrieve > > a resultset that has a record with one of the 8bit ascii characters I > > get a > > message from jboss (see error message below. > > > > My question is there a way to configure the postgres jdbc driver to > > allow > > for this range of characters? > > > > 2004-10-26 16:54:51,167 ERROR [STDERR] > > 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. > > 2004-10-26 16:54:51,167 ERROR [STDERR] at > > org.postgresql.core.Encoding.decodeUTF8(Encoding.java:287) > > 2004-10-26 16:54:51,167 ERROR [STDERR] at > > org.postgresql.core.Encoding.decode(Encoding.java:182) > > 2004-10-26 16:54:51,167 ERROR [STDERR] at > > org.postgresql.core.Encoding.decode(Encoding.java:198) > > 2004-10-26 16:54:51,167 ERROR [STDERR] at > > org.postgresql.jdbc1.AbstractJdbc1ResultSet.getString(AbstractJdbc1Resul > > tSet.java:201) > > 2004-10-26 16:54:51,167 ERROR [STDERR] at > > org.postgresql.jdbc1.AbstractJdbc1ResultSet.getString(AbstractJdbc1Resul > > tSet.java:475) > > 2004-10-26 16:54:51,168 ERROR [STDERR] at > > payroll.DeptWorkers.loadWorkers(DeptWorkers.java:52) > > 2004-10-26 16:54:51,168 ERROR [STDERR] at > > org.apache.jsp.manager_jsp._jspService(manager_jsp.jav > > >=20 > ---------------------------(end of broadcast)--------------------------- > TIP 3: if posting/reading through Usenet, please send an appropriate > subscribe-nomail command to majordomo@postgresql.org so that your > message can get through to the mailing list cleanly