f



Re: SAS Macro to delete a SAS dataset 131840

well, this one reminds me another thread recently discussed:

http://www.listserv.uga.edu/cgi-bin/wa?A2=ind0911c&L=sas-l&F=&S=&P=4034


On Wed, 2 Dec 2009 08:50:34 -0800, SAS Techies <sastechiesblog@GMAIL.COM>
wrote:

>Here?s a simple SAS Macro to delete a SAS dataset?It takes the name of
>the SAS dataset as the parameter?
>
>%macro deletedsn(dsname);
>
>%if %index(&dsname,'.') eq 0  %then %do; %let lib=work; %let
>dsn=&dsname; %end;
>%else %if %index(&dsname,'.') eq 0  %then %do; %let lib=%scan(&dsname,
>1,'.'); %let dsn=%scan(&dsname,1,'.'); %end;
>
>proc datasets lib=&lib nolist;
> delete &dsn;
>quit;
>%mend deletedsn;
>
>%deletedsn(new);
>%deletedsn(somelib.new);
>
>Read more @ http://sastechies.blogspot.com/2009/12/sas-macro-to-delete-sas-
dataset.html
0
dynamicpanel (212)
12/2/2009 5:26:59 PM
comp.soft-sys.sas 142828 articles. 3 followers. Post Follow

0 Replies
809 Views

Similar Articles

[PageSpeed] 10

Reply: