Recently we migrated our SAS software from SAS8.2 to SAS9.2. We use SAS under Z/OS. Below is the problem description,
I have a JCL with two steps,
Step1: Execute a sas program (say SASPGM1). I have specified a work library for this step. SASPGM1 creates an intermittent SAS dataset (e.g. DATASET1);
Step2: Execute another SAS program (say SASPGM2). Here I use the same work library as used in step1. But when I try to access the intermittent sas dataset (dataset1) created in step1, the program fails stating that WORK.DATASET1.DATA does not exist.
The same JCL works fine with SAS8 but not with SAS9.2. Below is the sample JCL:
//STEPA EXEC SAS
//WORK DD DSN=&&WORKLIB,DISP=(,PASS),UNIT=DISK
//SYSIN DD DSN=HLQ1.HLQ2.SAS(SASPGM1),DISP=SHR
//STEPB EXEC SAS
//WORK DD DSN=&&WORKLIB,DISP=(OLD,KEEP)
//SYSIN DD DSN=HLQ1.HLQ2.SAS(SASPGM2),DISP=SHR
I have workarounds, but I want to know why is this not working.
Since you are passing the SAS "WORK" allocated library, I expect your SAS CONFIG option WORKINIT is specified, rather than a previous default-behavior of NOWORKINIT.
If this is the case, your next option might be to discuss the default-assignment change with your SAS System Administrator. Then you can decide if your situation requires you to code NOWORKINIT or you may need to change from using WORK to some other LIBNAME that is not so dependent on the SAS system.