-->
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 with the Associations.
PostPosted: Wed Jun 29, 2011 5:46 am 
Newbie

Joined: Wed Jun 29, 2011 1:57 am
Posts: 3
Hi,

I am mapping few tables using xml based associations. The Condition is such that, when I fetch the data, the data need to be fetched with the condition that the deleted column should be 0 in all the tables, but I can give condition on the main query, so, the cascade select, would apply the filter condition on the first table only. Is it possible somehow, that the condition is applied on all the mapped tables with cascade select.

Example :-

Entity 1 : Abc { field1, field2, deleted}
Entity 2 : XYZ { field3, field4, AbcMapped, deleted}
Relationship : Xyz is mapped to Abc with one-to-one mapping with fetch = "select"

Now, using a HQL, I can write.. "FROM Abc where deleted = false"
But, this will populate, all XYZ, but I want to add restrictions on XYZ also about deleted, and so on because there are many entity mapped.

Thanks in Advance..


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.