Thread: DB2

SYNCPOINT ROLLBACK vs EXEC SQL ROLLBACK in CICS

Started by Anita • user4 replies204 viewsLast activity 3 weeks ago
Post #1
0 votes
Anita
Reputation
118
Posts: 23
Joined: May 29, 2025, 12:45 PM
Posted: Jul 19, 2026, 10:28 AM

Updating 3 DB2 tables in one CICS transaction. Spec says if any insert fails, undo all three.

I put EXEC SQL ROLLBACK in the error para and got weird abends. Someone on the team said use EXEC CICS SYNCPOINT ROLLBACK instead.

Is SQL ROLLBACK just wrong under CICS attach?

Post #2
0 votes
Dave
Reputation
356
Posts: 25
Joined: Jul 21, 2024, 2:55 PM
Posted: Jul 19, 2026, 12:28 PM

Under CICS, use CICS SYNCPOINT / SYNCPOINT ROLLBACK for the LUW. Do not issue DB2 COMMIT/ROLLBACK yourself. CICS owns the unit of work with the attachment.

Post #3
1 votes
Sandra
Reputation
198
Posts: 17
Joined: Oct 15, 2024, 8:30 AM
Posted: Jul 19, 2026, 3:28 PM

And issue a successful SYNCPOINT between logical groups if you only want the last group rolled back. Easy to undo more than you meant.

Post #4
0 votes
Anita
Reputation
118
Posts: 23
Joined: May 29, 2025, 12:45 PM
Posted: Jul 20, 2026, 1:28 PM

Switched to SYNCPOINT ROLLBACK. Error path behaves. Leaving this here so I remember.

You must be signed in to reply to this thread