From: | Joost Kraaijeveld <J(dot)Kraaijeveld(at)Askesis(dot)nl> |
---|---|
To: | Kris Jurka <books(at)ejurka(dot)com> |
Cc: | "pgsql-jdbc(at)postgresql(dot)org" <pgsql-jdbc(at)postgresql(dot)org> |
Subject: | Re: Is this error correct/possible? |
Date: | 2005-08-23 14:50:54 |
Message-ID: | 1124808654.27046.52.camel@panoramix.askesis.nl |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
On Tue, 2005-08-23 at 09:34 -0500, Kris Jurka wrote:
> It is allowed to be stored in the database because SQL_ASCII is not a real
> encoding. SQL_ASCII allows you to store anything you want and doesn't
> require you to tell the server what character set it actually is. The
> problem is on the return end, the JDBC driver asks the server to always
> return data in UTF-8 by setting the client_encoding appropriately. The
> server has no idea what the original encoding of the data was, so it has
> no means of converting it to unicode. It may happen to look like
> u-double-dot in your particular pgadmin3 client's encoding, but if that
> client's encoding was different it would show up as a different character.
> This is why the JDBC driver bails out instead of just picking a
> random character.
OK.
> > 2. If so, is this a JDBC bug?
>
> No. The JDBC documentation clearly states not to choose a SQL_ASCII
> database for your data.
>
> http://jdbc.postgresql.org/documentation/80/your-database.html
What if you don't have a choise? E.g. the database is already in SQL_ASCII? Can I convert the database from SQL_ASCII to UNCODE?
TIA
Joost
From | Date | Subject | |
---|---|---|---|
Next Message | Kris Jurka | 2005-08-23 14:55:57 | Re: Is this error correct/possible? |
Previous Message | Joost Kraaijeveld | 2005-08-23 14:46:50 | Re: Is this error correct/possible? |