This content has been marked as final.
Show 2 replies
-
1. Re: Strange behaviour wit 1:n collection with EJB 3.0 and To
wolfgangknauf Oct 30, 2007 6:35 AM (in response to statelessbean)Hi !
normally, you have to update both sides of a relation if it is bi-directional. So, if you want to add a BuildingsProd to a Planet, you have to do two things:
a)
BuildingsProd b = new BuildingsProd();
planet.getBuildingsProdList().add(b);
b)
b.setPlant (planet)
Hope this helps
Wolfgang -
2. Re: Strange behaviour wit 1:n collection with EJB 3.0 and To
statelessbean Oct 30, 2007 7:53 AM (in response to statelessbean)"Wolfgang Knauf" wrote:
Hi !
normally, you have to update both sides of a relation if it is bi-directional.
Yes i know that, but if I want only one sided mapping? Why this works on JBoss but on tomcat not?
In your example You force me to change half of my app to two sided relation.