Dealing with exception conditions

Every time you process an EXEC CICS command in one of your applications, CICS® automatically raises a condition, or return code, to tell you what happened.

You can choose that the CICS EXEC interface program passes this condition back to your application. This condition is also called a RESP value, because you can obtain it by using the RESP option in your command. Alternatively, you can obtain this value by reading it from the EXEC interface block (EIB). The condition is usually NORMAL.

If something unusual happens, you get an exception condition , that is, a condition other than NORMAL. By testing this condition, you can find out what has happened and, possibly, why.

Many exception conditions have an additional value (RESP2) associated with them, which gives further information. To obtain this RESP2 value, you can use the RESP2 option (in addition to the RESP option) in your command, or you can read it from the EIB.

Some conditions, even though they are not NORMAL, do not indicate an error situation. For example, an ENDFILE condition on a READNEXT command during a file browse, might indicate expected behavior. For information about all possible conditions and the commands on which they can occur, see Application development reference.