|
Do you really have to concatenate the datasets? Or is it sufficient to
"view" them as one dataset? Note that if you concatenate them you will
actually be reading each observation in each dataset.
If a view is permissible, add /view=new to the data statement in the
solution offered below:
%MACRO CONCAT(NUM);
DATA NEW /view=new;
SET %DO I=1 %TO #
TABLE&I
%END;
;
RUN;
%MEND CONCAT;
%CONCAT(2000);
-----Original Message-----
From: Prasad Ravi [mailto:prasad.s.ravi@HOUSEHOLD.COM]
Sent: Tuesday, March 05, 2002 5:02 PM
To: SAS-L@LISTSERV.UGA.EDU
Subject: Re: is there any efficient way concatenating
SAS data sets?
%MACRO CONCAT(NUM);
DATA NEW;
SET %DO I=1 %TO #
TABLE&I
%END;
;
RUN;
%MEND CONCAT;
%CONCAT(2000);
Prasad Ravi
"P. L" To:
SAS-L@LISTSERV.UGA.EDU
<li_9@HOTMAIL.COM cc:
> Subject:
is there any efficient way concatenating SAS data
Sent by: "SAS(r) sets?
Discussion"
<SAS-L@LISTSERV.U
GA.EDU>
03/05/2002 01:25
PM
Please respond to
"P. L"
I'll use SET to concatenating about 2000 SAS data sets
(table1-table2000).
Is there any efficient way to complete the job without
listing each file?
Any help will be greatly appreciated.
P.L
|