Page 1 of 1

Can temporary variable be stored even after the step fails

PostPosted: Mon Aug 02, 2010 2:08 pm
by ajuatsgp
Hi,
My output is TEMPORARY variable in one step.
I am using this TEMPORARY variable in the next step as input.
and I am using :
//SORTIN DD DSN=&&ABCD,DISP=(OLD,DELETE,KEEP) with an intention that if the job fails in the second step, to restart it from that step itself.

Please let me know if my understanding is correct or not.

Waiting for your response.

Re: Can temporary variable be stored even after the step fails

PostPosted: Mon Aug 02, 2010 2:11 pm
by NicC
Your understanding is wrong! You are using a temporary DATASET not a variable. Just allocate a normal dataset instead of the temporary one and make sure you have deletes at the right places to avoid DNVs (Duplicate Name on Volume).

Re: Can temporary variable be stored even after the step fails

PostPosted: Mon Aug 02, 2010 4:51 pm
by steve-myers
I presume you want to send the data to a later step that will execute with a COND=ONLY. I think your idea is awfully unreliable, but if you specify just DISP=(,PASS) (e.g., no conditional disposition) it oughta work. I will often do -
//A       EXEC PGM=IEFBR14
//DUMP     DD  DISP=(MOD,DELETE),UNIT=SYSALLDA,SPACE=(TRK,0),
//             DSN-&SYSUID..XXX.DUMP
//B       EXEC PGM=TESTPGM
//SYSMDUMP DD  DISP=(,DELETE,CATLG),UNIT=SYSDA,DSN=*.A.DUMP,
//             SPACE=(CYL,(100,50),RLSE)
to save a dump data set for later analysis using IPCS. The RLSE parameter does not seem to be terribly reliable, but sometimes it works. This is about the only time I do a conditional DISP in my work.