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.  [ 3 posts ] 
Author Message
 Post subject: Upgraded Hibernate from 3.2.2 to 3.2.6
PostPosted: Mon Aug 18, 2008 3:30 am 
Pro
Pro

Joined: Wed Oct 03, 2007 2:31 pm
Posts: 205
Hi there

I have recently upgraded hibernate in our product from 3.2.1 to Hibernate 3.2.6 and have found that our named queries are failing with no additional information. Has anyone had the same problem?


Thanks


Top
 Profile  
 
 Post subject:
PostPosted: Mon Aug 18, 2008 7:10 am 
Newbie

Joined: Mon Aug 18, 2008 6:37 am
Posts: 4
not like..

getHibernateTemplate().findByNamedParam("from Employee where :deptId = department) ", "deptId", departmentId);


Last edited by abiwap on Mon Aug 18, 2008 7:47 am, edited 1 time in total.

Top
 Profile  
 
 Post subject:
PostPosted: Mon Aug 18, 2008 7:10 am 
Newbie

Joined: Mon Aug 18, 2008 6:37 am
Posts: 4
with the upgraded hibernate release you need to use the respective field name to compare the fields in named queries

like..

getHibernateTemplate().findByNamedParam("from Employee where :deptId = department.id) ", "deptId", departmentId);

hope it helps!


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

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.