5 messages in com.mysql.lists.javaRe: Storing Korean Data
FromSent OnAttachments
Esteban Ramirez20 Jan 2004 01:51 
Ricardo Lopes20 Jan 2004 01:59 
Esteban Ramirez26 Jan 2004 22:29 
Esteban Ramirez26 Jan 2004 22:41 
Ricardo Lopes27 Jan 2004 01:45 
Subject:Re: Storing Korean Data
From:Esteban Ramirez (nets@yahoo.com.au)
Date:01/26/2004 10:41:38 PM
List:com.mysql.lists.java

the tables character set is set to, and must be, euckr as i need to sort its
data based on the korean alphabet. according to WinMySQLAdmin the server
variables are as follow (im under the impression these are only defaults)... character_set_server=latin1 character_set_system=utf8 character_set_database=latin1 character_set_client=latin1 charcter_set_connection=latin1

i override the following settings with every new connection from jsp... character_set_client=euckr character_set_connection=euckr character_set_results=euckr

...i will try altering the character_set_server and character_set_system
variables.

steven

Ricardo Lopes <lop@elevaconsult.pt> wrote: Probably you create your table with a different charset or something like that.

That a look in this pages: http://www.mysql.com/doc/en/Charset-table.html http://www.mysql.com/doc/en/Charset.html

Hope it helps

----- Original Message ----- From: "Esteban Ramirez" To: Sent: Tuesday, January 20, 2004 9:51 AM Subject: Storing Korean Data

hi all,

im building a small business management system using mysql 4.1.1a-alpha-nt, jsp on apache, and ie all running on win2000 professional.

the app needs to manage korean data as well as english. -my apps java locale is set to euc_kr. -the browser pages return content="text/html; charset=euc-kr". -the sql driver is set to SET character_set_client=euckr, SET character_set_connection=euckr, SET character_set_results=euckr. -the relevant table uses character set euckr.

the problem is the data seems to go in to the db ok but it just doesnt come back quite right.

example... korean input string: 0xb9 0xda 0xb9 0xcc 0xb6 0xf3 (said park-mi-ra in english) ...is stored ok in the db according to Mysql control center using a select

hex(?) query. unfortunately, after a relevant query in jsp the resulting string is...

output string: 0xffb9 0xffda 0xffb9 0xffcc 0xffb6 0xfff3

SO WHERE THE HELL DOES THE EXTRA 0xFF COME FROM!! i can strip every returned string but thats so crappy.

can anyone help me!!??