I'm using Hibernate 1.2, DB2 UDB 8.1; JDBC driver is IBM's UDB driver (type 4). I'm running into a problem when persisting an one-to-many mapping which works fine with Oracle. Attached are the log messages for both DB2 and Oracle.
Does anyone have similar issue? This issue seems to do an update statement with 0 row updated, somehow Hibernate throws back a "row not found" exception with DB2 whereas no such exception is raised with Oracle.
Thanks,
Kevin
DB2:
===
DEBUG cirrus.hibernate.impl.SessionFactoryImpl - prepared statement get: update hib_poll_actlist set pollcfg_id = ?, actionCause = ? where pollactlist_id = ?
2003-10-16 09:02:43,515 [ExecuteThread: '9' for queue: 'default'] DEBUG cirrus.hibernate.impl.SessionFactoryImpl - preparing statement
2003-10-16 09:02:43,515 [ExecuteThread: '9' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f844f23c00f844fda5660008' to parameter: 1
2003-10-16 09:02:43,515 [ExecuteThread: '9' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f844f23c00f844fda5660009' to parameter: 3
2003-10-16 09:02:43,515 [ExecuteThread: '9' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding 'POLL_CLOSED' to parameter: 2
2003-10-16 09:02:43,578 [ExecuteThread: '9' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f844f23c00f844fda5660008' to parameter: 1
2003-10-16 09:02:43,578 [ExecuteThread: '9' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding null to parameter: 3
2003-10-16 09:02:43,578 [ExecuteThread: '9' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding 'WINNING_RESPONSE' to parameter: 2
2003-10-16 09:02:43,640 [ExecuteThread: '9' for queue: 'default'] ERROR com.air2web.apps.tonotify.ejb.share.HibernateUtils - saveOrUpdate: Exception occurred:
cirrus.hibernate.HibernateException: SQL update or deletion failed (row not found)
at cirrus.hibernate.impl.NonBatchingBatcher.addToBatch(NonBatchingBatcher.java:23)
at cirrus.hibernate.impl.CollectionPersister.recreate(CollectionPersister.java:569)
at cirrus.hibernate.impl.ScheduledCollectionRecreate.execute(ScheduledCollectionRecreate.java:21)
at cirrus.hibernate.impl.SessionImpl.executeAll(SessionImpl.java:1688)
at cirrus.hibernate.impl.SessionImpl.execute(SessionImpl.java:1672)
at cirrus.hibernate.impl.SessionImpl.flush(SessionImpl.java:1613)
at com.air2web.apps.tonotify.ejb.share.HibernateUtils.saveOrUpdate(HibernateUtils.java:94)
Oracle:
=====
prepared statement get: update hib_poll_actlist set pollcfg_id = ?, actionCause = ? where pollactlist_id = ?
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.SessionFactoryImpl - preparing statement
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f84500b500f84508f93f0008' to parameter: 1
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f84500b500f84508f95e0009' to parameter: 3
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding 'POLL_CLOSED' to parameter: 2
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.BatcherImpl - Adding to batch
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f84500b500f84508f93f0008' to parameter: 1
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding null to parameter: 3
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding 'WINNING_RESPONSE' to parameter: 2
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.BatcherImpl - Adding to batch
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f84500b500f84508f93f0008' to parameter: 1
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding null to parameter: 3
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding 'PREVIOUS_WINNER_RESPONSE' to parameter: 2
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.BatcherImpl - Adding to batch
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f84500b500f84508f93f0008' to parameter: 1
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding null to parameter: 3
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding 'EARLY_RESPONSE' to parameter: 2
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.BatcherImpl - Adding to batch
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f84500b500f84508f93f0008' to parameter: 1
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding null to parameter: 3
2003-10-16 09:15:05,751 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding 'POLL_OPEN' to parameter: 2
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.BatcherImpl - Adding to batch
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f84500b500f84508f93f0008' to parameter: 1
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f84500b500f84508f95e000b' to parameter: 3
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding 'DAILY_MAX_RESPONSE' to parameter: 2
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.BatcherImpl - Adding to batch
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f84500b500f84508f93f0008' to parameter: 1
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding null to parameter: 3
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding 'NON_WINNING_RESPONSE' to parameter: 2
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.BatcherImpl - Adding to batch
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f84500b500f84508f93f0008' to parameter: 1
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding null to parameter: 3
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding 'VALID_RESPONSE' to parameter: 2
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.BatcherImpl - Adding to batch
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f84500b500f84508f93f0008' to parameter: 1
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding null to parameter: 3
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding 'INVALID_RESPONSE' to parameter: 2
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.BatcherImpl - Adding to batch
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f84500b500f84508f93f0008' to parameter: 1
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding null to parameter: 3
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding 'MULTIPLE_RESPONSE' to parameter: 2
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.BatcherImpl - Adding to batch
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding '4028e6c6f84500b500f84508f93f0008' to parameter: 1
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding null to parameter: 3
2003-10-16 09:15:05,782 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.type.StringType - binding 'LATE_RESPONSE' to parameter: 2
2003-10-16 09:15:05,829 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.BatcherImpl - Adding to batch
2003-10-16 09:15:05,829 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.CollectionPersister - Inserting collection: Poll/choices#4028e6c6f84500b500f84508f93f0007
2003-10-16 09:15:05,829 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.BatcherImpl - Executing batch size: 11
2003-10-16 09:15:05,829 [ExecuteThread: '11' for queue: 'default'] DEBUG cirrus.hibernate.impl.SessionFactoryImpl - closing statement
|