Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [eclipselink-users] @ManyToMany and @PrivateOwned

No, unfortunately a @PrivateOwned is not supported on a @ManyToMany mapping and you must still manage the removes from that mapping as you normally would.

Cheers,
Guy

----- Original Message ----- From: "khaskett" <khaskett@xxxxxxxxxxx>
To: <eclipselink-users@xxxxxxxxxxx>
Sent: Tuesday, July 21, 2009 12:11 PM
Subject: [eclipselink-users] @ManyToMany and @PrivateOwned



Will this work if I use @PrivateOwned on a ManyToMany relationship, such that
if a Phone is removed from the list in the Customer class will only the
relationship table get deleted?

Example -
   In Customer class:

   @ManyToMany
   @JoinTable(name="CUST_PHONES")
   @PrivateOwned
   public Set getPhones() { return phones; }

   In PhoneNumber class:

   @ManyToMany(mappedBy="phones")
   public Set getCustomers() { return customers; }



--
View this message in context: http://www.nabble.com/%40ManyToMany-and-%40PrivateOwned-tp24590764p24590764.html
Sent from the EclipseLink - Users mailing list archive at Nabble.com.

_______________________________________________
eclipselink-users mailing list
eclipselink-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/eclipselink-users




Back to the top