Win a copy of OCP Java SE 8 Programmer II Exam Study Guide this week in the OCP forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

UTF-8 Encoding problem  RSS feed

Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
HI Everyone ,

Have below problem for which i seek solution.
I am trying to fetch a value stored in oracle db column which has Japanese currency symbol Yen ¥. However value when fetched is distorted. It gets converted in ?. Witnessed in logs and db column when same is stored.
Application is deployed on tomcat and has spring and hibernate with OS as Unix.

At first i thought issue is with hibernate. However when i tried a sample standalone program with spring-hibernate layer and run it on unix, it correctly fetched and printed correct Yen value.
So program outside tomcat runs fine but when deployed on tomcat the conversion doesnt happen correctly.

My questions are
a) Does tomcat has any encoding settings that gets applied to the application and would override other settings i.e if provided in hibernate (properties) or jdbc level (properties at url).
b) What is the best practice for making multilayered application UTF-8 compliant.

  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!