Date: Fri, 3 Nov 2006 07:27:31 -0800
Reply-To: Chris Jones <chrisj75@GMAIL.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Chris Jones <chrisj75@GMAIL.COM>
Organization: http://groups.google.com
Subject: Re: proc datasets does not work
In-Reply-To: <1162566810.959200.160510@m73g2000cwd.googlegroups.com>
Content-Type: text/plain; charset="iso-8859-1"
Ravi,
It's simply a case of a missing semi-colon in your PROC DATASETS
command...
proc datasets library=work kill;quit;
should be
proc datasets library=work; kill;quit;
Regards,
ranumako...@ihcis.com wrote:
> Hi,
>
> I am trying to write code to clean up work datasets (through parameter
> checking - if user wants it) at the end of the program. Below pasted is
> the code:
>
> %macro clean_up;
>
> proc datasets library=work kill;quit;
>
> proc print data=work.test;
> run;
>
> %mend clean_up;
>
> %let cleanup=Y;
>
> %let rc = %sysfunc(ifc(&cleanup=Y,%clean_up;,E));
> %put &rc;
>
> The IFC code seems to work, because the %clean_up macro is executed (I
> know this because the proc print works). But the proc datasets does
> nothing. The proc datasets works when I call the %clean_up macro
> explicitly outside the IFC.
>
> Can someone please explain why proc datasets is behaving like this?
> What am I missing?
>
> Thank you all very much in advance.
>
> Regards,
> Ravi
|