Re: Identify the record that caused unique constraint violation

2009-05-13 Thread Vadim
Well, you can try logging `java.sql.*` if you're not already doing it. The last statement before error should be what you're looking for. On Tue, May 12, 2009 at 11:57 PM, sjewett wrote: > > Hi All, > > We are using iBATIS 2.1.7. I'm getting a java.sql.BatchUpdateException: > ORA-1: unique

Re: Identify the record that caused unique constraint violation

2009-05-13 Thread sjewett
dm3 - Thank you. I'll try that. I have a related question: Is there a way to invoke the executeBatch() for the inserts and have iBATIS simply skip the record that gets the unique constraint violation, and keep going? Thanks again. -sjewett dm3 wrote: > > Well, you can try logging `java.sql

Re: Identify the record that caused unique constraint violation

2009-05-13 Thread Nicholoz Koka Kiknadze
It may be database dependent. Here's extract from oracle docs http://download.oracle.com/docs/cd/B10501_01/java.920/a96654/oraperf.htm After a batch exception, the update counts array can be retrieved using the getUpdateCounts() method of the BatchUpdateException object. This returns an int array