It would be nice if someone has an answer to the above question! Thanx.
Just a short description:
Two classes A and B have a one-to-many relationship (A 1 : n B), but the useful access path in my case is from B to A. So the best way to do this in Hibernate is to implement a many-to-one relationship from B to A. Now, if A gets deleted, I would like to set null the foreign keys of all affected Bs.
With SQL this is easily done with the ON DELETE SET NULL constraint. Since I don't want to use too much of SQL, is there a way to implement this in Hibernate?
Greetz
Grischa
|