-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: Encoding problem ? (WebSphere, DB2, JSF, Hibernate)
PostPosted: Fri Nov 24, 2006 1:11 pm 
Newbie

Joined: Fri Nov 24, 2006 12:50 pm
Posts: 1
Greetigns to all,

I have a strange problem.
Our J2EE application on WebSphere 5.1 using JSF and Hibernate can Insert to our DB2 table correctly (Greek characters).

When on the same table you try to execute through Hibernate a query 'Select ..... like 'GreekChars%'' it does not fetch anything.

Below is a fragment of the console log.
You can see my SystemOuts below
first I display the string entered in the page MyString -> I see it correctly
then the query that is built QueString and FQueString -> shown correctly
then when Hibernate displays the query you can see that the like clause is full of '??%' (below in red)

Have you seen that before ?

Thanks a lot for any answers


[24/11/2006 18:42:17:259 EET] 29b3cbb3 SystemOut O My String: ΓΚ%
[24/11/2006 18:42:17:259 EET] 29b3cbb3 SystemOut O *********************
[24/11/2006 18:42:17:259 EET] 29b3cbb3 SystemOut O My QueString: from HelpDeskUser as user where user.name like 'ΓΚ%'
[24/11/2006 18:42:17:259 EET] 29b3cbb3 SystemOut O My FQueString: from HelpDeskUser as user where user.name like 'ΓΚ%' and user.id.branch=38 and user.groups.gid in ('HLPTELLERROLE','HLPCHIEFTELLERROLE')
[24/11/2006 18:42:17:259 EET] 29b3cbb3 SystemOut O [2006-11-24 18:42:17,259] [Servlet.Engine.Transports : 2] [DEBUG] [HibernateSessionFactory] getCurrentSession - Hibernate Current Session Retrieaval From Factory Revealed : 814926783
[24/11/2006 18:42:17:259 EET] 29b3cbb3 SystemOut O [2006-11-24 18:42:17,259] [Servlet.Engine.Transports : 2] [DEBUG] [LogisticsBean] selectObjects - Invoking session bean Logistics selectObjects(). Session object hashcode: 814926783
[24/11/2006 18:42:17:259 EET] 29b3cbb3 SystemOut O [2006-11-24 18:42:17,259] [Servlet.Engine.Transports : 2] [DEBUG] [HibernateSessionFactory] getCurrentSession - Hibernate Current Session Retrieaval From Factory Revealed : 814926783
[24/11/2006 18:42:17:634 EET] 29b3cbb3 SystemOut O Hibernate: select .............. helpdeskus0_.GID as GID5_ from OTPHD.USERS helpdeskus0_ where (helpdeskus0_.NAME like '??%') and helpdeskus0_.BRANCH=38 and (helpdeskus0_.GID in ('HLPTELLERROLE' , 'HLPCHIEFTELLERROLE'))


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.