The ABEND command forces the current task to terminate abnormally. If a HANDLE ABEND command is in effect, control
will be transferred to the routine it specifies. Otherwise, control is returned to CICS. An optional storage dump can be produced.
Syntax
EXEC CICS
ABEND [ ABCODE(name) ]
[ CANCEL ]
[ NODUMP ]
END-EXEC.
Options
ABCODE
Specifies that a storage dump should be produced. The name supplied is used to identify the dump, and it should be a 4-character value with no leading spaces. If you omit the name, the dump is identified by ????. If you omit ABCODE, a dump is not produced.
CANCEL
Specifies that any active abend exit set up by a HANDLE ABEND command should be ignored.
NODUMP
Specifies that a dump should not be produced. Since this is the default if ABCODE isn’t coded, you’ll rarely use the NODUM
Exceptional conditions
No exceptional conditions are raised as a result of the ABEND command.
Notes and tips
- Don’t start an ABCODE name with the letter A because abend codes starting with A are reserved by CICS.
- Storage dumps are written to the CICS dump data sets. You’ll have to determine your installation’s procedures for printing dumps.
- Because the ABEND command causes your task to abend, dynamic transaction backout is invoked. As a result, any changes your task made to recoverable resources will be reversed.
Coding example
This example shows how to issue an ABEND command, producing a storage dump identified by the abend code R100.
9000-ABEND-PROGRAM.
*
ABEND ABCODE(‘R100’)
END-EXEC.