-->
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: Problem facing createQuery() Left Join
PostPosted: Mon Mar 10, 2008 10:47 am 
Newbie

Joined: Mon Mar 10, 2008 9:18 am
Posts: 3
Location: Chennai
hi,


i'm using createQuery("select...") for my project, i have a situation using left Outer join,

compare with left table non primary key column and right table primary key column,

Tables as follows

Code:
Table A

Primary Key ->AA

AA  BB   CC
1    xxx  9999
2    yyy  8888
3    zzz   8888

Table B
Primary Key->EEE

Foreign Key ->AA

EEE    FFF  AA
9999   ttt   1
8888  uuu  2
5555  yyy  3
6666  eee  4



Table A
AA --> Mapped as one to Many

Table B
EEE --> Mapped as one to many
AA --> Mapped as Many to one

I need to write Query like this

createQuery(" from A left outer join B on A.CC=B.EEE");

In hibernate how can i solve It, i need some help,

thank,


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.