Previous Topic: Detect and Prevent an AbendNext Topic: Change the Value in TASKNUM Dynamically


Determine the Cause of the Error

Confirm that the value stored in TASKNUM is not in valid arithmetic format by displaying its current value; that is, its value prior to the execution of the assignment statement that triggered the ASRA.

CA InterTest for CICS displays the current value of TASKNUM, as shown in the following screen.

CA InterTest for CICS Release 9.1.00 - PROTSYM FILE ABEND DETECTED BREAKPOINT COMMAND ===> Program= PLIDEMO Option # Stmt # Margin= 01 Search= ------------------------------------------------------------------------------- _____ TASKNUM | ?00000. ---------+--------------------------------------------------------------------- _ 636.1 CONTINUE_TASK: _ 637.1 MAPNUM = '00'; A ==>.1 1 TASKNUM = TASKNUM + 1; ==> ==> ASRA ABEND (0C7) detected and prevented. Caused by invalid decimal ==> arithmetic data format. ==> ==> Press PF1 for a detailed description. ==> _ 639.1 1 IF TASKNUM > 2 THEN _ 640.1 1 GOTO END_SESSION; _ 641.1 1 IF TASKNUM = 1 THEN _ 642.1 1 GOTO SENDSCR3; _ 643.1 1 GOTO END_SESSION; _ 644.1 _ 645.1 1 SENDSCR3: /** ASRA CONGRATULAT _ 646.1 /* EXEC CICS SEND MAP('DASRA')

When the AutoKeep Display feature is active, CA InterTest for CICS automatically displays the value(s) of the variable(s) associated with a line of code. In this case, TASKNUM displays in this specially formatted Keep window. On the left is the name of the data item; on the right the question mark in the first position indicates incorrect data content for the fields' datatype, in this case low values (binary zeros).

Up to six data items at a time display within the scrollable Keep window. This feature lets you see how the values of data items change as your program executes. The Keep window remains until you remove all data items from it.

Note: A full discussion of the Keep window is described in Keeping Data Items in the Keep Window in the chapter "Using CA InterTest for CICS To Debug Programs".

Now, look at the contents of TASKNUM. It does not contain a valid packed decimal value. Instead, it contains low‑values (binary zeros). PL/I does not let you assign a value to a field without initializing it.