-->
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: Lazy relationship for many-to-one
PostPosted: Wed Feb 02, 2005 4:31 pm 
Beginner
Beginner

Joined: Sun Nov 07, 2004 4:19 pm
Posts: 38
Read the rules before posting!
http://www.hibernate.org/ForumMailingli ... AskForHelp

[b]Hibernate version:[/b]

2.1.7

In order to make my many-to-one lazy in a given class I have to set the proxy or lazy attribute in the corresponding class. However, doing this affects all other classes having a many-to-one to the same class to be lazy. How can I get one many-to-one lazy and all the rest (many-to-one) not to be lazy.

Dino


Top
 Profile  
 
 Post subject:
PostPosted: Wed Feb 02, 2005 5:04 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
use Hibernate 3 ,)

_________________
Max
Don't forget to rate


Top
 Profile  
 
 Post subject:
PostPosted: Wed Feb 02, 2005 6:21 pm 
Hibernate Team
Hibernate Team

Joined: Thu Dec 18, 2003 9:55 am
Posts: 1977
Location: France
Quote:
2.1.7

In order to make my many-to-one lazy in a given class I have to set the proxy or lazy attribute in the corresponding class. However, doing this affects all other classes having a many-to-one to the same class to be lazy. How can I get one many-to-one lazy and all the rest (many-to-one) not to be lazy.


outer-join = "auto" for the only association you want to be lazy
outer-join = "true" for all the others

_________________
Anthony,
Get value thanks to your skills: http://www.redhat.com/certification


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.