-->
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: annotation mapping "loop" many-to-one
PostPosted: Tue Jun 03, 2008 4:06 pm 
Newbie

Joined: Tue Jun 03, 2008 3:59 pm
Posts: 1
hi,

i am trying to define a "loop" with annotation in hibernate,
something like the following without success:

[b]class Node
{
List<Node> nodes;
Node parentNode;
}[/b]


i guess i must define the mapping in a join table.
i try several mapping, but without success.
any ideas ?

many thanks.
eran.


Top
 Profile  
 
 Post subject: annotation map "loop" many-to-one->composite de
PostPosted: Wed Jun 04, 2008 6:42 am 
Newbie

Joined: Wed Jun 04, 2008 6:34 am
Posts: 3
http://www.hibernate.org/86.html


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jun 04, 2008 10:01 am 
Expert
Expert

Joined: Tue May 13, 2008 3:42 pm
Posts: 919
Location: Toronto & Ajax Ontario www.hibernatemadeeasy.com
Is this a many to many mapping? I'm not sure exactly what your'e tryign to do. There may be an easier way.

Here's a tutorial on mapping associations with Hibernate and annotations which you might find helpful:

http://www.hiberbook.com/HiberBookWeb/learn.jsp?tutorial=19mappingmanytomanyrelationships

_________________
Cameron McKenzie - Author of "Hibernate Made Easy" and "What is WebSphere?"
http://www.TheBookOnHibernate.com Check out my 'easy to follow' Hibernate & JPA Tutorials


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.