Hi all,
I have a problem with the following scenario:
There are two object, let's say A and B.
Object B is referenced by object A, but is nullable in object A.
When i delete object B, i do not wish to delete object A (no cascading), i just want to set the value A.b to null.
unfortunately deleting object B throws an exception stating:
DELETE statement conflicted with COLUMN REFERENCE constraint ......
I have a workaround for this problem (first setting attribute A.b to null and then saving object A) but i was wondering if there is a way to make hibernate do this automatically.
Thanks in advance
|