论坛首页 Java企业应用论坛

hibernate错误, unique constraint

浏览 1898 次
精华帖 (0) :: 良好帖 (0) :: 新手帖 (0) :: 隐藏帖 (0)
作者 正文
   发表时间:2011-09-01  
有在oracle集群环境下跑过jbpm4.1的吗?现在发现在集群环境下sequence好像有问题,jbpm4_task中的主键生成策略是native,用的hibernate_sequence,jbpm4_hist_task中的数据是从jbpm4_task拷贝过来,现在情况是偶尔会出现插入jbpm4_hist_task失败。

Caused by: java.sql.SQLException: ORA-00001: unique constraint (FTQCJR.SYS_C0069287) violated

	at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:112)
	at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:331)
	at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:288)
	at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:743)
	at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:213)
	at oracle.jdbc.driver.T4CPreparedStatement.executeForRows(T4CPreparedStatement.java:952)
	at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1160)
	at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3285)
	at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:3368)
	at org.hibernate.jdbc.NonBatchingBatcher.addToBatch(NonBatchingBatcher.java:23)
	at org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2247)
	... 106 more




论坛首页 Java企业应用版

跳转论坛:
Global site tag (gtag.js) - Google Analytics