Java Mailing List Archive

http://www.junlu.com/

Home » Home (12/2007) » Tomcat Users »

Re: Character Set Issues (windows vs. Unix)

Anton Tagunov

2003-09-16

Replies:

Hello Hans!

HL> When the application is installed on the windows server the particular
HL> character (which is some kind of spacing character in word) gets read out of
HL> the database as
HL> Ascii code 160,

HL> BUT on the Linux server the exact same routine reads it as ascii code 65533

HL> Same database, same application config - only difference is OS

HL> The JVM's are both set up as default english installs.

Fun story ideed :-)
Are you sure you get it wron from ResultSet.getString()?

Try doing

String s = rs.getString(x);
char c = s.charAt(y);
out.print((int)c);

Are you getting different character codes?

Anton


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@(protected)
For additional commands, e-mail: tomcat-user-help@(protected)


©2008 junlu.com - Jax Systems, LLC, U.S.A.