-->
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.  [ 2 posts ] 
Author Message
 Post subject: Updating query with multiple joins in where condition
PostPosted: Tue Mar 16, 2010 1:02 pm 
Newbie

Joined: Tue Mar 16, 2010 12:56 pm
Posts: 1
Hi,

I wanted to update a table data based on multiple joins with different table keys in where condition. My query is as follows.

Update table1 t1, table t2, table t3 set t1.col1=?, t1.col2=? where t1.col1=t2.col3 and t2.col3=t3.col4

I wanted to write the above query using Hibernate query language and update the table1 data based on the joins with t2 and t3 tables.

Please let me know how to perform this operation.

Thanks


Top
 Profile  
 
 Post subject: Re: Updating query with multiple joins in where condition
PostPosted: Tue Mar 16, 2010 2:33 pm 
Expert
Expert

Joined: Wed Mar 03, 2004 6:35 am
Posts: 1240
Location: Lund, Sweden
Hibernate doesn't support this kind of queries. See http://docs.jboss.org/hibernate/stable/ ... tch-direct


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 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:
cron
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.