Rejip,
When an update error or abend occurs, the unit of work is not complete, so IMS would issue a ROLB. Otherwise, you can check for any invalid SQLCODES and issue an implicit CALL CBLTDLI USING ROLB,IO-PCB to rollback the changes.
-PK.
I.T.Analyst
Tata Consultancy Services