Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Data Bases > Pgsql Interfaces Jdbc > Re: Character E...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 4 of 7 Topic 1921 of 2064
Post > Topic >>

Re: Character Encoding problem

by craig@[EMAIL PROTECTED] (Craig Ringer) Apr 7, 2008 at 12:34 PM

antony baxter wrote:

> Displaying 'input' character by character:
> Character 0 = '8211'
> Character 1 = '235'
> Character 2 = '8212'
> Character 3 = '196'
> Character 4 = '8212'
> Character 5 = '231'
> Character 6 = '8211'
> Character 7 = '937'
> Character 8 = '8212'
> Character 9 = '199'

There's your problem. Your *input* is mangled.

The above decodes to:

--e"---A"---c,--?---C,

So at some point you or some library you're using has done something
like read a utf-8 byte sequence from a file and shoved it character by
character into a String. Another possible culprit is a wrong (implicit?)
encoding conversion or cast from a byte array type to a unicode string
type.

The JDBC is storing exactly what you tell it to, and the good 'ol GIGO
rule is being applied.

--
Craig Ringer

-- 
Sent via pgsql-jdbc mailing list (pgsql-jdbc@[EMAIL PROTECTED]
)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-jdbc
 




 7 Posts in Topic:
Character Encoding problem
antony.baxter@[EMAIL PROT  2008-04-07 08:29:47 
Re: Character Encoding problem
antony.baxter@[EMAIL PROT  2008-04-07 09:04:01 
Re: Character Encoding problem
craig@[EMAIL PROTECTED]   2008-04-07 11:48:54 
Re: Character Encoding problem
craig@[EMAIL PROTECTED]   2008-04-07 12:34:44 
Re: Character Encoding problem
craig@[EMAIL PROTECTED]   2008-04-07 12:36:56 
Re: Character Encoding problem
craig@[EMAIL PROTECTED]   2008-04-07 11:38:58 
Re: Character Encoding problem
craig@[EMAIL PROTECTED]   2008-04-07 12:35:37 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat Oct 11 19:17:02 CDT 2008.