What it means
NOTFND tells the program that what it asked for does not exist. What the 'item' is depends on the command: for example a record key on a file read, a host name on WEB OPEN, or a code page on WEB RECEIVE.
If the program does not handle NOTFND, CICS ends the task with abend AEIM. Treat it as a normal outcome where a missing item is expected.
Typical causes
- The key, name or value passed to the command does not match anything that exists.
- The program built the key or name wrongly (padding, case, wrong field).
- The data the program expected has not been written yet or was deleted.
- Setup values such as host names or code pages are wrong (IBM-documented cases for WEB OPEN and WEB RECEIVE).
How to fix it
- Code RESP (and RESP2) on the command and test the value with DFHRESP.
- Display the exact key or name the program used and compare it with the data.
- Check RESP2 for the specific reason on that command.
- Decide what the program should do when the item is missing instead of letting the task abend.
Example
Illustrative only; names and values are invented.
EXEC CICS READ FILE('CUSTFILE') INTO(WS-CUST) RIDFLD(WS-KEY)
RESP(WS-RESP) END-EXEC
IF WS-RESP = DFHRESP(NOTFND) ...