Date: Mon, 22 Oct 2001 11:50:02 -0400
Reply-To: "Chakravarthy, Venky" <Venky.Chakravarthy@PFIZER.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: "Chakravarthy, Venky" <Venky.Chakravarthy@PFIZER.COM>
Subject: Re: Appending all the datasets in one library to all the datasets
in another
Content-Type: text/plain; charset="iso-8859-1"
Kendall,
(1) You can create a view of all the datasets using DICTIONARY.TABLES and
(2) Use call execute to issue as many proc appends as there are memnames.
For example if you have lib1 as your base lib and you want to append the
corresponding members from lib2 then the following works in v6.12 NT:
proc sql ;
create view names as
select memname
from dictionary.tables
where libname = "LIB1" ;
quit ;
data _null_ ;
set names ;
call execute ("proc append base = lib1."||memname||
" data = lib2."||memname||" ;") ;
run ;
Regards,
Venky
#****************************************#
# E-mail: venky.chakravarthy@pfizer.com #
# swovcc@hotmail.com #
# Phone: (734) 622-1963 #
#****************************************#
-----Original Message-----
From: Kendall Golladay [mailto:kgollada@UI.URBAN.ORG]
Sent: Friday, October 19, 2001 5:51 PM
To: SAS-L@LISTSERV.UGA.EDU
Subject: Appending all the datasets in one library to all the datasets
in another
Hi,
I was wondering if anyone knew of a quick way to append all the datasets in
one library to all those in another library (to the datasets in this
library with the same names). I am trying to develop a program that will
process monthly data updates and then add the updates to existing files.
If there are any other suggestions for performing an operation like this,
please let me know.
Thanks in advance,
Kendall Golladay
|