  | Mailing List | | Home | | Forum Home | | JBoss - Java Application Server | | Tomcat - JSP/Servlet container | | Struts - A MVC web framework | | iText - An open source PDF Java Library | | JDOM - JDOM XML Parser | | J2EE - A mailing list for Java(tm) 2 Platform, Enterprise Edition | | JSP - A mailing list about Java Server Pages specification and reference | | J2EE Pattern - An interest list for Sun Java Center J2EE Pattern Catalog | | Servlet - A mailing list for discussion about Sun Microsystem's Java Servlet API Technology | |
Struts & Hibernate
|
|
|
  | | | - problem while deleting processInstance | - problem while deleting processInstance 2007-08-08 - By iseyfi
Back Hi,
I am trying to delete a processIntance using GrapSession object. What I have looks like
GraphSession session = context.getGraphSession(); ProcessInstance processInstance = null; if (session != null) { processInstance = session.getProcessInstance (processInstanceId); if (processInstance != null) { session.deleteProcessInstance(processInstance); } }
When I do this i get a hibernate exception.
org.springframework.dao.DataIntegrityViolationException : Hibernate operation: Could not execute JDBC batch update; SQL [delete from JBPM_MODULEINSTANCE where ID_=?]; Cannot delete or update a parent row: a foreign key constraint fails ( `forms/jbpm_swimlaneinstance`, CONSTRAINT `FK_SWIMLANEINST_TM` FOREIGN KEY ( `TASKMGMTINSTANCE_`) REFERENCES `jbpm_moduleinstance` (`ID_`)); nested exception is java.sql.BatchUpdateException : Cannot delete or update a parent row: a foreign key constraint fails (`forms/jbpm_swimlaneinstance`, CONSTRAINT `FK _SWIMLANEINST_TM` FOREIGN KEY (`TASKMGMTINSTANCE_`) REFERENCES `jbpm _moduleinstance` (`ID_`)) java.sql.BatchUpdateException : Cannot delete or update a parent row: a foreign key constraint fails (`forms/jbpm_swimlaneinstance`, CONSTRAINT `FK _SWIMLANEINST_TM` FOREIGN KEY (`TASKMGMTINSTANCE_`) REFERENCES `jbpm _moduleinstance` (`ID_`))
am I missing something?
thanks
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic &p=4072248#4072248
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode =reply&p=4072248 __ ____ ____ ____ ____ ____ ____ ____ ____ ____ jboss-user mailing list jboss-user@(protected) https://lists.jboss.org/mailman/listinfo/jboss-user
|
|
 |