openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Klesk <>
Subject @ManyToMany, Set, join table and primary key
Date Tue, 15 Mar 2011 16:34:19 GMT
Hi all,

I have a problem with the @ManyToMany annotation on a Set container (OpenJPA
2.1.0) :
When I generate my database (Derby 10.7) the generated join table have two
foreign keys but no primary key !

My question is : How can I add a primary key (or unique) constraint on the
join table with OpenJPA to prevent duplicate row inside DB table ?

Best regards,

View this message in context:
Sent from the OpenJPA Users mailing list archive at

View raw message