Note that there are some explanatory texts on larger screens.

plurals
  1. POnot able to delete
    text
    copied!<p>Hi I am able to add record but not able to delete record.</p> <p>It gives the following error:</p> <pre><code>[ERROR] 2010-02-20 13:38:16 (JDBCExceptionReporter.java:logExceptions:78) ORA-02292: integrity constraint (BANKNET.FK_DDA_DEAL_ADVISOR) violated - child record found [ERROR] 2010-02-20 13:38:16 (AbstractFlushingEventListener.java:performExecutions:301) Could not synchronize database state with session org.hibernate.exception.ConstraintViolationException: could not delete: [com.bofa.crme.dda.domain.ManualDDAData#10041] </code></pre> <p>Here are my mapping files:</p> <p>Child table:</p> <pre><code>&lt;hibernate-mapping&gt; &lt;class name="com.bofa.crme.dda.domain.DealAdvisor" table="DDA_DEAL_ADVISOR" schema="BANKNET"&gt; &lt;composite-id name="comp_id" class="com.bofa.crme.dda.domain.DealAdvisorPK"&gt; &lt;key-property name="advisorNm" column="ADVISOR_NM" type="java.lang.String" length="100" access="property"/&gt; &lt;key-many-to-one name="ddaDeal" column="DDA_DEAL_NO" class="com.bofa.crme.dda.domain.ManualDDAData" /&gt; &lt;/composite-id&gt; &lt;property name="modifiedBy" column="MODIFIED_BY" type="java.lang.String" update="true" insert="true" access="property" /&gt; &lt;property name="modifiedDt" column="MODIFIED_DATE" type="java.util.Date" update="true" insert="true" access="property"/&gt; &lt;/class&gt; &lt;/hibernate-mapping&gt; </code></pre> <p>Parent table:</p> <pre><code>&lt;hibernate-mapping&gt; &lt;class name="com.bofa.crme.dda.domain.ManualDDAData" table="DDA_DEAL" schema="BANKNET" &gt; &lt;id name="ddaDealNumber" column="DDA_DEAL_NO" type="java.lang.Long"&gt; &lt;generator class="sequence"&gt; &lt;param name="sequence"&gt;BANKNET.DDA_DEAL_ID_SEQ&lt;/param&gt; &lt;/generator&gt; &lt;/id&gt; &lt;property name="clientGCI" type="java.lang.String" update="true" insert="true" access="property" column="GCI" /&gt; &lt;set name="dealAdvisors" inverse="true" cascade="all,all-delete-orphan" lazy="false"&gt; &lt;key column="DDA_DEAL_NO" not-null="true" on-delete="cascade"/&gt; &lt;one-to-many class="com.bofa.crme.dda.domain.DealAdvisor" /&gt; &lt;/set&gt; &lt;/class&gt; &lt;/hibernate-mapping&gt; </code></pre> <p>Anyone know why it is not working ?</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload