-->
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: Embeddable not support ManyToMany in Annotations?
PostPosted: Tue Mar 27, 2007 11:57 pm 
Newbie

Joined: Tue Mar 27, 2007 11:34 pm
Posts: 13
Hi all, can anyone tell me is hibernate annotation supported many-to-many in embeddable?

My situations:
Class Diagram:
Image

ERD:
Image

Seems composite-id must using separate "Embeddable" class, so I use the "IdClass" for the original class and put the "ManyToMany" to the embeddable class, but when I passing the annotation, the following exception is thrown:
Code:
Exception in thread "main" java.lang.NullPointerException
   at org.hibernate.cfg.AnnotationBinder.processElementAnnotations(AnnotationBinder.java:1148)
   at org.hibernate.cfg.AnnotationBinder.fillComponent(AnnotationBinder.java:1671)
   at org.hibernate.cfg.AnnotationBinder.bindId(AnnotationBinder.java:1704)
   at org.hibernate.cfg.AnnotationBinder.bindClass(AnnotationBinder.java:663)
   at org.hibernate.cfg.AnnotationConfiguration.processArtifactsOfType(AnnotationConfiguration.java:452)
   at org.hibernate.cfg.AnnotationConfiguration.secondPassCompile(AnnotationConfiguration.java:268)
   at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1286)


Top
 Profile  
 
 Post subject:
PostPosted: Tue Apr 24, 2007 12:37 pm 
Beginner
Beginner

Joined: Wed Oct 29, 2003 10:43 am
Posts: 38
Location: Chicago
Can you show your hibernate code ie annotaed classes?

_________________
LET IT BE :)


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.