X-Original-To: pgsql-jdbc-postgresql.org@postgresql.org Received: from localhost (wm.hub.org [200.46.204.128]) by postgresql.org (Postfix) with ESMTP id F32399FB281 for ; Sun, 20 Aug 2006 09:17:42 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.128]) (amavisd-new, port 10024) with ESMTP id 88297-04 for ; Sun, 20 Aug 2006 12:17:32 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey- Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by postgresql.org (Postfix) with ESMTP id B150C9FA502 for ; Sun, 20 Aug 2006 09:17:28 -0300 (ADT) Received: from list by ciao.gmane.org with local (Exim 4.43) id 1GEmEy-0000FK-91 for pgsql-jdbc@postgresql.org; Sun, 20 Aug 2006 14:17:20 +0200 Received: from ppp-82-135-73-63.dynamic.mnet-online.de ([82.135.73.63]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 20 Aug 2006 14:17:20 +0200 Received: from spam_eater by ppp-82-135-73-63.dynamic.mnet-online.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 20 Aug 2006 14:17:20 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: pgsql-jdbc@postgresql.org From: Thomas Kellerer Subject: Small problem with special characters Date: Sun, 20 Aug 2006 14:17:14 +0200 Lines: 24 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 8bit X-Complaints-To: usenet@sea.gmane.org X-Gmane-NNTP-Posting-Host: ppp-82-135-73-63.dynamic.mnet-online.de User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; de; rv:1.8.0.5) Gecko/20060719 Thunderbird/1.5.0.5 Mnenhy/0.7.4.0 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200608/81 X-Sequence-Number: 15608 Hello, I'm having a small problem with inserting german umlauts. The PG database was created with the default code page (by accident) and thus ended up with 'WIN1251'. Now from within a Java program I'm trying to insert a value into the database that contains the character 'ö'. Now when doing that, the JDBC driver throws an error: character 0xc3b6 of encoding "UTF8" has no equivalent in "WIN1251" [SQL State=22P05] What I don't understand, is that this character is contained in the windows code page. The value itself is retrieved from a JDBC connection to a HSQLDB database, so the string handling is Java internal only. I can convert the database to UTF8 that is not the problem, the main reason I'm writing, is that I'd like to understand what is going on here. Does this mean, that I can only access UTF8 enabled databases with the JDBC driver? Thanks Thomas