开发者

Not to delete child record on deleting parent table record

I am little bit newbie in Hibernate and DBMS and stuck on a problem. I have two table. One is A and second is B. There is Many-to-One relationship between these two tables. Now on removing one record from table A I do not want 开发者_Python百科to delete the record from table B. What type of cascading strategy should I apply.

Please help.


Here's what Hibernate manual says.
Based on what you wrote I think you should use cascade="persist,merge,save-update"

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜