Beginner |
![Beginner Beginner](./images/ranks/beginner.gif) |
Joined: Thu Sep 04, 2003 2:52 am Posts: 29
|
Hibernate version: 2.1.4
the parent class mapping file
---------------------
<class name="Element" table="tbl_element">
<id...>
</class>
the child class mapping file
-------------------------
<class name="Relation" table ="tbl_relation">
<many-to-one name="networkElement" class="Element" column="Network_ID" cascade="delete"/>
</class>
I use cascade="delete" to perform this operation: when element is deleted,then the relations are deleted too. but it does not work.Why!
|
|