If you ever encountered a BatchUpdateException, you probably realized how frustrating it is to debug the same. Unlike a jdbc exception where the stacktrace is fine grained to database errors, Batch exceptions encapsulate all the errors within and throw this rather “useless” message. There is nothing you can do about it unless you want to write a Custom Exception handler (not to mention the intricacies of how a batch gets executed)
However if you happen to have access to the sourcecode where this piece of code gets executed, there is one simple suggestion
Make the batch_size = 1 and see how the same app throws up the stack trace, this time around with the actual db error
Post a Comment