Processing a "NOT FOUND" condition when using a KEY FILE in CULPRIT.

Document ID : KB000022461
Last Modified Date : 14/02/2018
Show Technical Document Details

Introduction:

This document explains how it is possible to invoke type 7 processing logic for record not found conditions (0326), when a KEY FILE is being used in CULPRIT.

Instructions:

In order to invoke type 7 code when one of the entries in a culprit KEY FILE is not found (error-status 0326) it is necessary to use an ALTERNATE PATH ID.

In the following example, the automatic path is 01 and the alternate path is 02:

IN DB SS=EMPSS01   
PATH01 EMPLOYEE(02)   
KEYFILE 80 KF=1,4   
01510001 EMP-ID-0415   
01510010 EMP-FIRST-NAME-0415   
01510030 EMP-LAST-NAME-0415   
01520001 EMP-ID-0415   
01520010 '** EMPLOYEE NOT FOUND **'   
017   IF PATH-ID EQ '01' 100   
017   IF PATH-ID EQ '02' 200   
017   DROP   
017100 TAKE 1   
017200 TAKE 2 

The above source produces output like this:-

2 INPUT RECORDS READ 23 KATHERINE O'HEARN 4,321 ** EMPLOYEE NOT FOUND **

Additional Information:

For more information, see the manual "CA Culprit for CA IDMS User Guide" chapter 14 "Additional CA IDMS/DB Facilities", "Retrieving Record Types by Key".