• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Problem in displaying unicode data from DB2 in JSP

 
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I have unicode data in DB2. I am trying to display it in my JSP. I am doing following:
<%
while(rs.next())
{
name = rs.getString(1);
value = new String(name.getBytes("UTF8"));
%>
<TR>
<TD width="345"><%=value%></TD>
</TR>
<%
i++;
}
%>

and i have set the character encoding to UTF-8 in jsp. It dose display japanese characters but not correctly.

I have checked the UTF-8 value which is coming from database is right by putting them in string variable.

Please respond.

Thanks in advance.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic