I have a
Java application that can call a stored procedure multiple times in a loop. This stored procedure updates a row in a database table. Suppose my Java application calls a stored procedure five times in a loop. Suppose the stored procedure updates the row successfully four times, but fails to update the row during the last time. How can I get my Java application to do a rollback on all of the previous transactions if the last attempted update failed?