I've got a saved procedure inside a loop that's known as about 100 occasions for around a quarter-hour once daily. The saved procedure consists of deletion claims. What's the best practice for error handling around the client side after performing the saved procedure.

I merely experience Error Resume Next meaning when the saved procedure fails or occasions out it's just known as again around the next iteration. I've 'SET XACT_ABORT ON' within the saved procedure to make sure that the explicit transaction within the saved procedure is folded back when the command object occasions in VB6. The saved procedure passes a mistake code being an output variable to this program however i am wandering contrary else is needed.