When you want a QUERY to constrain an INPUT process (the regular INPUT Child
Constraints can't be satisfied using CC's 'EQ' comparison operator only), you
can use the following technique:
Create a JOB with Job Steps:
QUERY
UPDATE (uq=query)
INPUT
All three processes use the same PCF.
The UPDATE's Start of Process is:
SCRATCH AAA FILENAME CACHE? Y
CREATE AAA FILENAME SHARE? Y CACHE? NOLOAD
OPEN AAA FILENAME SHARE? Y CACHE? N
The UPDATE's Record frame contains only:
OPEN AAA FILENAME SHARE? Y CACHE? Y
WRITE AAA FILENAME
OPEN AAA FILENAME SHARE? Y CACHE? N
The INPUT's JobStep's Pre-Invocation sets the following detached workfield:
SET AAA WORK USE-CACHED-PCF = 1
The INPUT's Start of Process contains:
IF AAA WORK USE-CACHED-PCF EQ 1
T OPEN AAA FILENAME SHARE? Y CACHE? Y
The INPUT's Post-Invocation sets:
SET AAA WORK USE CACHED PCF = 0
This example does not pass changes to the CACHEed version on to the disk
version. You'd have to put code in the INPUT's End of Process for that. |