But LASTCC applies only to the instruction that is being checked. As
soon as a new instruction is issued (or a higher level nested
instruction completes), LASTCC becomes the CC of this instruction.
E.g. Consider the following:
IF 1 EQ 1 DO
SET LASTCC EQ 8
END
The LASTCC following the above would be 0, because the IF-END completed
with CC = 0 (regardless of the SET LASTCC EQ 8 in-between).
So, change your LASTCC to MAXCC throughout - then check MAXCC instead of
LASTCC.
Micheal Butz wrote:
I tried interrogating lastcc and setting
MAXCC still comes up with 0
Sent from my iPhone
On Mar 5, 2014, at 6:37 PM, CM Poncelet <[email protected]> wrote:
Try setting MAXCC EQ <whatever, e.g. 4 or 8> instead of LASTCC.
Micheal Butz wrote:
Hi,
I have 2 files and would lime to see If one or both or none exist
I am using IDCAMS if-else sequence
With a command of print for this
However I am always coming up with a cc of 0 in the jcl for this step
E.G.
Let's say filea is empty so is fileb
Print indataset(filea) count (1)
If lastcc ne 0 then do
Print indataset(fileb) count (1)
If lastcc = 0 then set lastcc = 8
Else
Set lastcc = 0
End
Else do
Print indataset(fileb) count(1)
If lastcc ne 0 then
Set lastcc = 4
End
I always cone up with a 0 for the IDCAMS job step when it should be in the case
of 2 empty file 8
Sent from my iPhone
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN