users@glassfish.java.net

Re: More columns in 'ManyToMany' JoinTable

From: <glassfish_at_javadesktop.org>
Date: Mon, 12 Feb 2007 13:57:17 PST

Just to clarify, the issue comes from the fact that the Join table of a ManyToMany is managed by container, and not by the application. This is crux of the problem.

There is simply no way that the container can "know" what the values of the other fields in the join table can be, and there's no mechanism to expose the lifecycle of these join table entries where you might be able to fill those values in. Also, the lifecycle simply is guaranteed. It would not be unheard of to see those join columns constantly being deleted and replaced rather than updated, which of course potentially obliterates any extra data in those columns.

So, the only way to expose the lifecycle of those rows simply is to manage them all yourself.
[Message sent by forum member 'whartung' (whartung)]

http://forums.java.net/jive/thread.jspa?messageID=203528