-->
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: Hibernate outerjoin
PostPosted: Mon Jun 21, 2010 6:03 pm 
Newbie

Joined: Wed Feb 10, 2010 7:19 pm
Posts: 12
select A.ENT_ID,A.LBL_SEQ_NBR,PRIM_VND_NM,CHARTC_VAL_DESC,
A.EXP_TYP_NBR from mlt_vnd_alloc A
INNER JOIN XMT_VND V ON A.ENT_ID = V.ENT_ID
LEFT OUTER JOIN TVSCHVL B ON A.LBL_SEQ_NBR = B.CHARTC_SEQ_NBR
AND (b.CHARTC_SEQ_NBR <> 0) AND (CHARTC_CDE =3)
WHERE ( A.EFF_BEG_DTE <= '2010-06-09' AND A.EFF_END_DTE >= '2010-06-09')
ORDER BY A.ENT_ID,A.LBL_SEQ_NBR

I would like to generate the above sql using hibernate. The problem iam facing is, Iam not able to give conditions for the outer join before the where condition

select A.ENT_ID,A.LBL_SEQ_NBR,PRIM_VND_NM,CHARTC_VAL_DESC,
A.EXP_TYP_NBR from mlt_vnd_alloc A
INNER JOIN XMT_VND V ON A.ENT_ID = V.ENT_ID
LEFT OUTER JOIN TVSCHVL B ON A.LBL_SEQ_NBR = B.CHARTC_SEQ_NBR
AND (b.CHARTC_SEQ_NBR <> 0) AND (CHARTC_CDE =3)
WHERE ( A.EFF_BEG_DTE <= '2010-06-09' AND A.EFF_END_DTE >= '2010-06-09')
ORDER BY A.ENT_ID,A.LBL_SEQ_NBR

It always generates after the where condition. How can i do that.


Top
 Profile  
 
 Post subject: Re: Hibernate outerjoin
PostPosted: Fri Jun 25, 2010 9:47 am 
Newbie

Joined: Wed Feb 10, 2010 7:19 pm
Posts: 12
Can anyone reply to this please


Top
 Profile  
 
 Post subject: Re: Hibernate outerjoin
PostPosted: Mon Jun 28, 2010 9:30 am 
Newbie

Joined: Wed Feb 10, 2010 7:19 pm
Posts: 12
Please can anyone help..............


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.