You are viewing a plain text version of this content. The canonical link for it is here.
Posted to torque-user@db.apache.org by Robert Kromkamp <r....@pagelink.nl> on 2006/01/31 13:28:22 UTC

id broker occurs duplicate key

Hi All,

I get the error below. I'm using torque 3.1.1 and postgres 8.0 . I wonder why the quantity of the specific record in id-table is increased and one second later it will fail during an insert. This table is only accessed by using the idbroker method of Torque. It worked for 2 months perfectly except for now. Does anyone has an idea?

2006/01/31 11:05:59 | - Forced id retrieval - no available list
2006/01/31 11:05:59 | - updateQuantity: UPDATE ID_TABLE SET QUANTITY = 3 WHERE TABLE_NAME = 'LOCKING'
2006/01/31 11:05:59 | - updateNextId: UPDATE ID_TABLE SET NEXT_ID = 1373 WHERE TABLE_NAME = 'LOCKING'
2006/01/31 11:06:00 | - Exception
2006/01/31 11:06:00 | org.apache.torque.TorqueException: java.sql.SQLException: ERROR: duplicate key violates unique constraint "locking_pkey"
2006/01/31 11:06:00 | 	at org.apache.torque.util.BasePeer.throwTorqueException(BasePeer.java:200)
2006/01/31 11:06:00 | 	at org.apache.torque.util.BasePeer.insertOrUpdateRecord(BasePeer.java:867)

Cheers,
Robert


---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org