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: Link table
PostPosted: Thu Mar 13, 2008 2:31 pm 
Newbie

Joined: Thu Mar 13, 2008 2:04 pm
Posts: 6
I use Hibernate with annotations:
- A Team has a number of members (OneToMany)
- I use a link table (team_members) to link a team and its members

Everything goes well, until I also register (annotatedClasses) the link table as a separate class too (to be able to add properties to the link table).

I get an exception: "java.sql.BatchUpdateException: failed batch"

Am I handling this the wrong way?

Info: the link table in between the Team and Member class is defined using:
(@JoinTable(name = "team_members", joinColumns = @JoinColumn(name = "team_id"), inverseJoinColumns = @JoinColumn(name = "user_id")))


Top
 Profile  
 
 Post subject: Re: Link table
PostPosted: Tue Mar 18, 2008 11:22 am 
Newbie

Joined: Thu Mar 13, 2008 2:04 pm
Posts: 6
Anyone?


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