-->
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: Can foreign key one-to-one association support proxy lazy?
PostPosted: Mon Dec 19, 2005 11:34 am 
Newbie

Joined: Mon Dec 19, 2005 8:28 am
Posts: 1
I want to implement lazy loading in one-to-one mapping using foreign key association, but failed. I have implemented lazy loading using primary key association.

I found in 3.1 release note improvement section, it says:
* [HHH-221] - Proxy for one-to-one with property-ref

What does it mean? Can hibernate 3.1 support proxy lazy loading in foreign key one-to-one association?


Top
 Profile  
 
 Post subject:
PostPosted: Tue Dec 20, 2005 4:36 am 
Newbie

Joined: Fri Nov 25, 2005 11:24 am
Posts: 4
That’s the same question I having been confused for a long time.

Is there any way for me to use lazy-loading for one-to-one association using foreign key?

Think I have the following one-to-one relationship:

Code:
<one-to-one name="house" constrained="true" fetch="select" property-ref="owner" cascade="all" lazy="proxy"/>

<many-to-one name="owner"   class="Person" column="owner_id" unique="true" cascade="all"/>



Constrained=”true” is useless.

Is that because a proxy will be created only when an Id is found? Why this Id is needed?

Does that mean there is no way for foreign-key one:one lazy loading?

Thank you


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:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.