|
Chris:
Looking at your code I see a problem, I think. If SAS accepts your unit=aff,
in your proc sort you are asking for both DATA1 and DATA2. I'm pretty sure
that SAS needs to open both at the start of the sort procedure. And, it
won't be able to mount them at the same time.
-----Original Message-----
From: Chris Smith [mailto:cpsmith@AGFINANCE.COM]
Sent: Friday, November 17, 2000 8:19 AM
To: SAS-L@LISTSERV.UGA.EDU
Subject: An MVS Conundrum...More
Can I use the UNIT=AFF= within my libname statements, a la:
LIBNAME DATA1 TAPE 'XXXX.XXXX1' DISP=(NEW,CATLG,CATLG) UNIT=TAPE
BLKSIZE=27468;
DATA DATA1.STEP1;
SET SOMEDATA.FROMAN.SQLVIEW;
RUN;
LIBNAME DATA2 TAPE 'XXXX.XXXX2' DISP=(NEW,CATLG,CATLG) UNIT=AFF=DATA1
BLKSIZE=27468;
PROC SORT DATA=DATA1.STEP1 OUT=DATA2.STEP2;
BY VAR1 VAR2 VAR3;
RUN;
LIBNAME DATA1 CLEAR;
LIBNAME DATA3 'XXXX.XXXX3' DISP=(NEW,CATLG,CATLG) <MASSIVE AMOUNTS OF DASD>;
DATA3.STEP3;
SET DATA2.STEP2;
BY VAR1 VAR2;
<SOME SIMPLE MATH MAKING NEW VARS>;
<A ROLLUP>;
<A KEEP>;
RUN;
LIBNAME DATA41 TAPE 'XXXX.XXXX41' DISP=(NEW,CATLG,CATLG) UNIT=AFF=DATA2
BLKSIZE=27468;
DATA DATA3.SUBSET1;
SET DATA3.STEP3;
<AN IF>;
RUN;
PROC RANK ... OUT=DATA41.SUBSET1;
RUN;
LIBNAME DATA2 CLEAR;
LIBNAME DATA42 TAPE 'XXXX.XXXX42' DISP=(NEW,CATLG,CATLG) UNIT=AFF=DATA41
BLKSIZE=27468;
DATA DATA3.SUBSET2;
SET DATA3.STEP3;
<AN IF>;
RUN;
PROC RANK ... OUT=DATA42.SUBSET2;
RUN;
LIBNAME DATA41 CLEAR;
<MORE SUBSETTING AS ABOVE>
First, can I use UNIT=AFF in my libname statements the way I have above?
Second, can I "daisy chain" the referbacks the way I have?
Obviously, I want to avoid using JCL to do this. My goal is to use as
little JCL as possible, and get into the comfortable realm of SAS quickly
to do what I need to do. I don't care how long it take for this program to
run (clearly). My only concern is that I tie up just one tape unit at a
time, maybe two. Please take a look at the above code and let me know if it
will work.
The help everyone has given me recently has been invaluable, by the
way, and I am trying to keep my posts to a minimum. Thanks, Chris
|