| Readonly ManyToMany mapping? [message #540003] |
Mon, 14 June 2010 10:53  |
Kevin Messages: 2 Registered: June 2010 |
Junior Member |
|
|
I have a many-to-many association database view and I mapped entity A and B using this association database view, the problem now is that when I need to delete A, it try to delete the association entry in the db view.. How do a map a many-to-many in a ready only fashion? Just like in manytoone we have insertable="false", etc.
Btw, I'm using XML for the mappings.
Thanks,
|
|
|
| Re: Readonly ManyToMany mapping? [message #540860 is a reply to message #540003] |
Thu, 17 June 2010 09:51  |
James Sutherland Messages: 1877 Registered: July 2009 |
Senior Member |
|
|
EclipseLink has a readOnly option on all of its mappings that can be used to avoid the delete from the join table. Unfortunately there is currently no support to enable this in annotations or xml, you need to use a DescriptorCustomizer to get the ManyToManyMapping and set it to be readOnly.
Please log a bug that readOnly is not supported from annotations and xml, and vote for the bug.
James : Wiki : Book : Blog : Twitter
|
|
|
Powered by
FUDForum. Page generated in 0.01643 seconds