Re: JDBC and unicode characters
"Ian Stanton (Anywhere)" <[email protected]>
| Newsgroups | gmane.comp.db.mysql.java |
|---|---|
| Message-ID | <[email protected]> |
I've been exploring this problem and my research suggests that this
is more likely to be a problem with Java or Java and the bash shell.
This can be illustrated by compiling and running this class.
// You will need to save this as a unicode encoded file
// To compile the file use javac -encoding UTF-8 NiHao.java
public class NiHao {
public static void main(String[] args) {
String nihao = "你好" ;
System.out.println("The Chinese for hello is: " + nihao) ;
}
}
// If in the line String nihao ... "??" is displayed in this email or
on the web page then look at this link to see the proper Chinese
characters. http://freespace.virgin.net/i.stanton/NiHao.html .
Basically for me the output is wrong. I do not get The Chinese for
hello is 你好.
I get The Chinese for hello is ??.
Does anyone have any idea what is going on here?
Send instant messages to your online friends http://uk.messenger.yahoo.com
--
MySQL Java Mailing List
For list archives: http://lists.mysql.com/java
To unsubscribe: http://lists.mysql.com/[email protected]