Re: How to get the location of SAS code in the same SAS code thru #3 685847> From: Alok
> I am facing a problem in which I need to get the
> location/path of a SAS code in a macro variable. I need to
> use the macro variable in the same SAS code. Is there any SAS
> option available which can do this for me? Or is there a code
> snippet which can achieve the same purpose?
- - - MyMacro.sas - - -
%macro MyMacro(path=);
%*...;
%Mend;
- - - MyProgram.sas - - -
%Let Path2MyMacro = c:\temp\MyMacro.sas;
%Include "&Path2MyMacro.";
%MyMacro(path = &Path2MyMacro.);
Ron Fehd the macro maven CDC Atlanta GA USA RJF2 at cdc dot gov
...
Re: How to get the location of SAS code in the same SAS code thru #3 1561853For Jobs run in BATCH you can use
&SYSPROCESSNAME
or something like
%let pgmname=%sysfunc(getoption(sysin));
or for FILES submitted from Enhanced Editor in WINDOWS SAS/V9 you can
use the following to access these two environment variables.
%let FNAME = %sysget(SAS_EXECFILENAME);
%let FPATH = %sysget(SAS_EXECFILEPATH);
On 4/11/07, Alok <alok.rustagi@gmail.com> wrote:
> Hi all,
>
> I am facing a problem in which I need to get the location/path of a
> SAS code in a macro variable. I need to use the macro variable in the
> same SAS code. Is there any SAS option available which can do this for
> me? Or is there a code snippet which can achieve the same purpose?
>
> Can you please help me out as soon as possible since I need to deliver
> this tomorrow. Any help will be greatly appreciated.
>
>
> Thanks,
> Alok
>
...
Re: Include SAS code w/o including SAS code #4I actually never want to store the macro code. I only want it available in a
temp file which I then consume. For example:
%macro xyz;
data temp.temp4;
...do some sas stuff...
run;
%mend;
I want to save the contents, formatted, into a text file (i.e.
c:\temp\program.sas) which I can then consume in another application. I also
want to execute the code. Hence:
%xyz;
Save the contents of the macro file to a text file with CRLF included. I
don't want the run, merely the statements.
Thoughts?
Alan
Alan Churchill
Savian
www.savian.net
-----Original Message-----
From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Fehd,
Ronald J. (CDC/CCHIS/NCPHI)
Sent: Tuesday, August 12, 2008 8:15 AM
To: SAS-L@LISTSERV.UGA.EDU
Subject: Re: Include SAS code w/o including SAS code
you want to save the macro code in its own file
access then depends on modifying one of the three uses of the word:
SASautos
Tutorials
A SASautos Companion: Reusing Macros
http://tinyurl.com/45nzzk for:
http://www2.sas.com/proceedings/sugi30/267-30.pdf
Ron Fehd the macro maven CDC Atlanta GA USA RJF2 at cdc dot gov
> -----Original Message-----
> From: Alan Churchill
> Ok, I think this might be doable but I am drawing a blank.
> Suppose I have this code:
> %macro xyz;
> data temp.temp4;
> .do some sas stuff.
> run;
> %mend;
>
> Is there a way to write the macro statements out to a file? I
> can run them
> but I would also like to ...
Re: Include SAS code w/o including SAS codeI want the statements only, not the processing.
Alan
Alan Churchill
Savian
www.savian.net
-----Original Message-----
From: ./ ADD NAME=Data _null_, [mailto:iebupdte@gmail.com]
Sent: Tuesday, August 12, 2008 6:20 AM
To: Alan Churchill
Cc: SAS-L@listserv.uga.edu
Subject: Re: Include SAS code w/o including SAS code
You need to provide more details. It is unclear to me if you want the
statements generated by the macro MPRINT/MFILE written to the file or
the MACRO definition FILE/PUT.
Syntax
MFILE | NOMFILE
MFILE
routes output produced by the MPRINT option to an external file. This
is useful for debugging.
On 8/12/08, Alan Churchill <savian001@gmail.com> wrote:
> All,
>
>
>
> Ok, I think this might be doable but I am drawing a blank.
>
>
>
> Suppose I have this code:
>
>
>
> %macro xyz;
>
> data temp.temp4;
>
> .do some sas stuff.
>
> run;
>
> %mend;
>
>
>
> Is there a way to write the macro statements out to a file? I can run them
> but I would also like to save them outside of SAS.
>
>
>
> Thanks,
>
> Alan
>
>
>
> Alan Churchill
> Savian
> <http://www.savian.net/> www.savian.net
>
...
Re: Running sas code on mainframe through SAS-UNIX #4Something like this should be possible as I have done it in the past. Note
the "site filetype=jes" which submits your JCL/SAS Program to the MVS
internal reader.
ftp -nv hostname << EOT
user userid/password
ascii
lcd jcldirectory
site filetype=jes
put sasjobwithjcl
quit
EOT
You should get back something like "250 Transfer completed successfully"
and "known to JES as <jobnumber>"
MM
On Fri, 15 Sep 2006 13:15:48 +0200, Robert Bardos <bardos2@ANSYS.CH> wrote:
>Hi,
>
>I ought to be busily doing other things so I'll just sketch out a...
Re: FW: Include SAS code w/o including SAS codeOn Tue, 12 Aug 2008 13:36:52 +0000, Don Henderson
<donaldjhenderson@HOTMAIL.COM> wrote:
>resending as I did not mean to send to just Andre
>
>----------------------------------------
>> From: donaldjhenderson@hotmail.com
>> To: wielki@ined.fr
>> Subject: RE: Include SAS code w/o including SAS code
>> Date: Tue, 12 Aug 2008 13:34:41 +0000
>>
>>
>> Alan,
>>
>> If you want the generated SAS code try (untested):
>>
>> data _null_;
>> file "code.sas";
>> length code $32000;
>> code = resolve('%xyz');
>> put code;
>> run;
>>
>> You may want to format it (e.g., new line whenever you start a new
statement).
>>
>> HTH,
>> donh
>>
>> ----------------------------------------
>>> Date: Tue, 12 Aug 2008 14:52:02 +0200
>>> From: wielki@INED.FR
>>> Subject: Re: Include SAS code w/o including SAS code
>>> To: SAS-L@LISTSERV.UGA.EDU
>>>
>>> Alan,
>>> not precisely clear what you are searching
>>> think thus also about this kind of program
>>> in addition to the mprint mfile answer of ~data _null_
>>> HTH
>>> Andre
>>>
>>> libname malibmac "d:\temp";
>>> options mstores sasmstore=malibmac;
>>> %macro foobar(aarg)/store source des='nothing or interresting';
>>> ...
Re: Include SAS code w/o including SAS code #8You are not consistent. One time you say you don't want to execute
the macro then you say you do.
Question: Where is the "macro" when YOU begin to want it?
Please describe your processing in complete detail.
On 8/12/08, Alan Churchill <savian001@gmail.com> wrote:
> I actually never want to store the macro code. I only want it available in a
> temp file which I then consume. For example:
>
> %macro xyz;
> data temp.temp4;
> ...do some sas stuff...
> run;
> %mend;
>
>
> I want to save the contents, formatted, into a text file (i.e.
> c:\temp\program.sas) which I can then consume in another application. I also
> want to execute the code. Hence:
>
> %xyz;
>
> Save the contents of the macro file to a text file with CRLF included. I
> don't want the run, merely the statements.
>
> Thoughts?
>
> Alan
>
> Alan Churchill
> Savian
> www.savian.net
>
>
> -----Original Message-----
> From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Fehd,
> Ronald J. (CDC/CCHIS/NCPHI)
> Sent: Tuesday, August 12, 2008 8:15 AM
> To: SAS-L@LISTSERV.UGA.EDU
> Subject: Re: Include SAS code w/o including SAS code
>
> you want to save the macro code in its own file
>
> access then depends on modifying one of the three uses of the word:
> SASautos
>
> Tutorials
> A SASautos Companion: Reusing Macros
>
> http://tinyurl.com/45nzzk fo...
Re: Include SAS code w/o including SAS code #9Remember the formatting/indentation is lost in macro anyway as white space =
is not relevant. The best you can do is what mprint does for you - a new st=
atement on column 1 on on new line.
=20
-don> Date: Tue=2C 12 Aug 2008 08:38:31 -0600> From: savian001@GMAIL.COM> S=
ubject: Re: Include SAS code w/o including SAS code> To: SAS-L@LISTSERV.UGA=
..EDU> > Good Don. I should have remembered that trick from SGF. One minor i=
ssue=2C it> doesn't preserve formatting. Other than doing the string split =
myself=2C any> suggestions?> > Alan> > Alan Churchill> Savian> www.savian.n=
et> > > -----Original Message-----> From: SAS(r) Discussion [mailto:SAS-L@L=
ISTSERV.UGA.EDU] On Behalf Of Don> Henderson> Sent: Tuesday=2C August 12=2C=
2008 7:37 AM> To: SAS-L@LISTSERV.UGA.EDU> Subject: FW: Include SAS code w/=
o including SAS code> > resending as I did not mean to send to just Andre> =
> ----------------------------------------> > From: donaldjhenderson@hotmai=
l.com> > To: wielki@ined.fr> > Subject: RE: Include SAS code w/o including =
SAS code> > Date: Tue=2C 12 Aug 2008 13:34:41 +0000> >> >> > Alan=2C> >> > =
If you want the generated SAS code try (untested):> >> > data _null_=3B> > =
file "code.sas"=3B> > length code $32000=3B> > code =3D resolve('%xyz')=3B>=
> put code=3B> > run=3B> &g...
Re: Include SAS code w/o including SAS code #2Alan,
not precisely clear what you are searching
think thus also about this kind of program
in addition to the mprint mfile answer of ~data _null_
HTH
Andre
libname malibmac "d:\temp";
options mstores sasmstore=malibmac;
%macro foobar(aarg)/store source des='nothing or interresting';
%put arg=&arg;
%mend;
%copy foobar/source;
Alan Churchill a �crit :
> All,
>
>
>
> Ok, I think this might be doable but I am drawing a blank.
>
>
>
> Suppose I have this code:
>
>
>
> %macro xyz;
>
> data temp.temp4;
>
> .do some sas stuff.
>
> run;
>
> %mend;
>
>
>
> Is there a way to write the macro statements out to a file? I can run them
> but I would also like to save them outside of SAS.
>
> bname malibmac "d:\f\";
>
> Thanks,
>
> Alan
>
>
>
> Alan Churchill
> Savian
> <http://www.savian.net/> www.savian.net
>
>
--
Andr� WIELKI
INED (Institut National d'Etudes D�mographiques)
Service Informatique
133 Boulevard Davout 75980 Paris Cedex 20
m�l : wielki@ined.fr t�l : 33 (0) 1 56 06 21 54
...
Re: Include SAS code w/o including SAS code #5you want to save the macro code in its own file
access then depends on modifying one of the three uses of the word:
SASautos
Tutorials
A SASautos Companion: Reusing Macros
http://tinyurl.com/45nzzk for:
http://www2.sas.com/proceedings/sugi30/267-30.pdf
Ron Fehd the macro maven CDC Atlanta GA USA RJF2 at cdc dot gov
> -----Original Message-----
> From: Alan Churchill
> Ok, I think this might be doable but I am drawing a blank.
> Suppose I have this code:
> %macro xyz;
> data temp.temp4;
> .do some sas stuff.
> run;
> %mend;
>
> Is there a way to write the macro statements out to a file? I
> can run them
> but I would also like to save them outside of SAS.
...
Re: Include SAS code w/o including SAS code #11Thanks Ian.
I actually switched it over to a %include since readability is critical
here. The only other method I can think of is to use datalines but that is
not as convenient either.
The underlying problem behind this exercise was:
How can I have a set of valid SAS statements be filed into a text file and
also be available for execution?
Immediately, I said %include since that is obvious. However, I was hoping to
also be able to see the lines and make quick modifications in the editor.
Since I have had time to think about it some more, I decided to go ahead and
split it out into 2 programs and simply %include them. That way I retain
formatting. The only negative is that they are now in 2 tabs but I can live
with that.
All of the exploration done by people and pointing out various options has
been helpful. The formatting though is critical and I don't want to run my
cleaner on it.
Sometimes it is best to just KISS.
Alan
Alan Churchill
Savian
www.savian.net
-----Original Message-----
From: iw1junk@comcast.net [mailto:iw1junk@comcast.net]
Sent: Tuesday, August 12, 2008 10:29 AM
To: SAS(r) Discussion
Cc: Alan Churchill
Subject: Re: Include SAS code w/o including SAS code
Summary: Macro generation of correct SAS code requires SAS execution.
#iw-value=1
Alan,
I do not see how this is possible.
Consider:
%macro q ( seed=0 ) ;
%local cum ;
data w ( keep = r ) ;
do i = 1 to 20 ;
r = ranuni ( &seed ) ;
output ;
...
Re: Include SAS code w/o including SAS code #12OK, now I get it. You don't know that you already have what you need.
In your example you say...
Suppose I have this code:
%macro xyz;
data temp.temp4;
.do some sas stuff.
run;
%mend;
So you have it you don't need to get it you've already got it. The
formatting that you desire is right there, no problem.
If the macro is in aggregate storage location then you also "have it".
It is waiting be auto called, read with infile, or opened with an
editor.
If it is stored compiled and the source was saved you can look at the
source just as Andre suggested using %copy.
If calling the macro with RESOLVE returns gt 32767 characters what do
you do then?
You could read the compiled macro from the work.sasmacr. Limited
testing suggests that the formatting you desire is preserved in the
catalog entry.
filename ft56f001 catalog 'work.sasmacr.<NAME>.macro';
data _null_;
infile ft56f001;
input;
list;
run;
On 8/12/08, Alan Churchill <savian001@gmail.com> wrote:
> I don't believe there is inconsistency in my statement. I don't want the log
> (run), just the statements. A macro is a macro so I can always run it if
> need be but the main gist is that I need the statements.
>
> I will just break the statements myself and do the formatting using Don's
> technique.
>
> Thanks for the help,
> Alan
>
> Alan Churchill
> Savian
> www.savian.net
>
>
> -----Original Message---...
Re: Include SAS code w/o including SAS code #13What you ask can be done (just about <anything> can be done in sas), but
at what price? The put statement is your friend--think if you were to
generate a whole job, not just a macro. The problem comes if you have any
macro variables that would need to be resolved when the second job runs--
now you have to play with quoting, so that sas doesn't try to interpret
them at compile time. And that can cause horrible headaches, esp if there
are some macro vars that you do want evaluated at compile time.
I have some code that was used on the mainframe to generate dynamically
created jobs that were then submitted either right into the reader or
across the wire to another machine--jcl, including macro resolutions for
pds, member name and ds name, as well as the job logic. It was a real
hassle to maintain, and difficult for a new person to pick up without
doing a lot of hand holding (or try and be patient, and after the 5th
mistake, they figure it out). Trying to coordinate batch processing
across multiple machines, when you have an established production window,
where you can't be waiting indefinitely for a dataset that may never come--
presents its own set of challenges.
If you're still curious, let me know and I'll pass it along.
CH
On Tue, 12 Aug 2008 10:38:11 -0600, Alan Churchill <savian001@GMAIL.COM>
wrote:
>Thanks Ian.
>
>I actually switched it over to a %include since readability is critical
>here. The only other method I can th...
Re: Include SAS code w/o including SAS code #6Good Don. I should have remembered that trick from SGF. One minor issue, it
doesn't preserve formatting. Other than doing the string split myself, any
suggestions?
Alan
Alan Churchill
Savian
www.savian.net
-----Original Message-----
From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Don
Henderson
Sent: Tuesday, August 12, 2008 7:37 AM
To: SAS-L@LISTSERV.UGA.EDU
Subject: FW: Include SAS code w/o including SAS code
resending as I did not mean to send to just Andre
----------------------------------------
> From: donaldjhenderson@hotmail.com
> To: wielki@ined.fr
> Subject: RE: Include SAS code w/o including SAS code
> Date: Tue, 12 Aug 2008 13:34:41 +0000
>
>
> Alan,
>
> If you want the generated SAS code try (untested):
>
> data _null_;
> file "code.sas";
> length code $32000;
> code = resolve('%xyz');
> put code;
> run;
>
> You may want to format it (e.g., new line whenever you start a new
statement).
>
> HTH,
> donh
>
> ----------------------------------------
>> Date: Tue, 12 Aug 2008 14:52:02 +0200
>> From: wielki@INED.FR
>> Subject: Re: Include SAS code w/o including SAS code
>> To: SAS-L@LISTSERV.UGA.EDU
>>
>> Alan,
>> not precisely clear what you are searching
>> think thus also about this kind of program
>> in addition to the mprint mfile answer of ~data _null_
>> HTH
>> Andre
>>
&...
Re: Include SAS code w/o including SAS code #3You need to provide more details. It is unclear to me if you want the
statements generated by the macro MPRINT/MFILE written to the file or
the MACRO definition FILE/PUT.
Syntax
MFILE | NOMFILE
MFILE
routes output produced by the MPRINT option to an external file. This
is useful for debugging.
On 8/12/08, Alan Churchill <savian001@gmail.com> wrote:
> All,
>
>
>
> Ok, I think this might be doable but I am drawing a blank.
>
>
>
> Suppose I have this code:
>
>
>
> %macro xyz;
>
> data temp.temp4;
>
> .do some sas stuff.
>
> run;
>
> %mend;
>
>
>
> Is there a way to write the macro statements out to a file? I can run them
> but I would also like to save them outside of SAS.
>
>
>
> Thanks,
>
> Alan
>
>
>
> Alan Churchill
> Savian
> <http://www.savian.net/> www.savian.net
>
...
Re: Include SAS code w/o including SAS code #7I don't believe there is inconsistency in my statement. I don't want the log
(run), just the statements. A macro is a macro so I can always run it if
need be but the main gist is that I need the statements.
I will just break the statements myself and do the formatting using Don's
technique.
Thanks for the help,
Alan
Alan Churchill
Savian
www.savian.net
-----Original Message-----
From: ./ ADD NAME=Data _null_, [mailto:iebupdte@gmail.com]
Sent: Tuesday, August 12, 2008 9:05 AM
To: Alan Churchill
Cc: SAS-L@listserv.uga.edu
Subject: Re: Include SAS code w/o including SAS code
You are not consistent. One time you say you don't want to execute
the macro then you say you do.
Question: Where is the "macro" when YOU begin to want it?
Please describe your processing in complete detail.
On 8/12/08, Alan Churchill <savian001@gmail.com> wrote:
> I actually never want to store the macro code. I only want it available in
a
> temp file which I then consume. For example:
>
> %macro xyz;
> data temp.temp4;
> ...do some sas stuff...
> run;
> %mend;
>
>
> I want to save the contents, formatted, into a text file (i.e.
> c:\temp\program.sas) which I can then consume in another application. I
also
> want to execute the code. Hence:
>
> %xyz;
>
> Save the contents of the macro file to a text file with CRLF included. I
> don't want the run, merely the statements.
>
> Thoughts?
>
> Alan...
Re: Include SAS code w/o including SAS code #14Charles,
I did very similar things across multiple datacenters with NDM and the JCL
Reader awhile back. And yes, explaining a SyncSort, EasyTrieve, SAS
milkshake to a newbie was an exercise in frustration. Hell, I told them
early on that SyncSort had limited commands (7 at the time?) but would take
them years to master threw them for a loop. Welcome to binary ;-]
That said, I think the details of what I am doing need something else.
The problem with tossing out a problem on SAS-L (and elsewhere) is that the
particular need is generalized to the point of losing what the original
constraints are bound by. After looking at the proposals and the ideas, I am
still faced with what I need to accomplish. Hence, while the %include was
not what I wanted, it worked out the best.
Melding 2 systems together, SAS and .NET, makes me choose alternatives that
aren't as pretty as I would like. Nonetheless, I have something that works
now.
....and I forge ahead.
BTW, this isn't client work but SAS community work for my spare time. I
appreciate everything everyone has contributed and it will be returned.
Alan
Alan Churchill
Savian
www.savian.net
-----Original Message-----
From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of
charles.harbour@ACT.ORG
Sent: Wednesday, August 13, 2008 5:23 PM
To: SAS-L@LISTSERV.UGA.EDU
Subject: Re: Include SAS code w/o including SAS code
What you ask can be done (just about <anything> can be done in sas), but
at what price? T...
Re: Include SAS code w/o including SAS code #10Summary: Macro generation of correct SAS code requires SAS execution.
#iw-value=1
Alan,
I do not see how this is possible.
Consider:
%macro q ( seed=0 ) ;
%local cum ;
data w ( keep = r ) ;
do i = 1 to 20 ;
r = ranuni ( &seed ) ;
output ;
end ;
run ;
data _null_ ;
set w end = eof ;
cum + r ;
if eof then
call symputx ( "cum" , cum ) ;
run ;
title1 "Cum = &cum" ;
%mend q ;
This macro ends up generating a TITLE statement. However, that
title statement depends on the execution of the previous steps.
Hence it cannot be generated by the macro facility without actually
executing the previously generated code.
The problem is similar to that of using CALL EXECUTE to generate
SAS code via a macro call. In the case of CALL EXECUTE one can work
around the problem by using %NRSTR to hide the call during the DATA
step execution, but you have explicitly required the macro to generate
correct code without executing. Now there is no work around.
In essence you are asking, "Is the macro facility so weak that there
is a program that can predict the output of every macro without
executing it?" Since that output can depend on the execution of SAS
code, one must first be able to predict the result of executing every
SAS program without actually doing the executing. It seems highly
unlikely that the SAS Institute is up to the jo...
Re: Reusing code from SAS Program in another SAS Program #4In response to a question by Keith, Paul Choate suggested using
%INC. The suggestion is reasonable, but not his explanation.
Since %INC is a macro you can put it anywhere in open code and
it will read the code snippet during compilation.
%INC is neither a macro nor a macro instruction. It is one of a
few old SAS commands that begin with a %-sign and predate the
current macro language. This can be shown by a batch job run
with the option NOMACRO. Here is the log.
NOTE: SAS (r) Proprietary Software Release 8.2 (TS2M0)
Licensed to The SAS Learning Edition V2.0, Site
...
Re: Exit SAS gracefully / Condtional execution of code without SAS macro #4True, using the abort statement doesn't always end the session, but it
also doesn't always stop execution of subsequent code, which is the
goal.
The original problem was "Ideally, I'd like SAS to stop processing
subsequent statements but I can't find any code that will
stop SAS elegantly without it closing down the whole "SAS System" (such
as ABORT)." As far as I know, that's correct - there's no SAS
statement which means "ignore the rest of the input but don't shut
down".
%IF in open code really would be a nice solution (though not...
Re: Diffrence between SAS coding and SAS implementationSai,
It might be fancy term that HR guys coined or It might be installing SAS on
cross platform operating systems. It may be of great important with BI
installation is pretty complicated managers in this list might know what it
is ??????? Sorry could not help you much
thanks
On 1/10/07, saikumarkorrapati@gmail.com <saikumarkorrapati@gmail.com> wrote:
>
> Hi Group,
>
> i just wanted to clarify my doubt
>
> I am working with SAS in financial domain from past 2 years.
>
> Usually i do codoing for conversion of all input files ( whatever the
> type like excel ,. flat files etc) and generate the reports and
> maintaing data bases and performence tuning etc ...
>
>
> But recently i come across the words from some of the business managers
> - SAS implementation.
>
> What is mean by SAS implementation ?
>
> implematation is like automation of all the tasks?
>
> or still it mean SAS in all phases of the project ?
>
>
>
> Thanks in advance.
>
> Sai kumar
>
...
Include SAS code w/o including SAS codeAll,
Ok, I think this might be doable but I am drawing a blank.
Suppose I have this code:
%macro xyz;
data temp.temp4;
.do some sas stuff.
run;
%mend;
Is there a way to write the macro statements out to a file? I can run them
but I would also like to save them outside of SAS.
Thanks,
Alan
Alan Churchill
Savian
<http://www.savian.net/> www.savian.net
...
Re: SAS code beautifier or SAS Tidy #3Yes indeed. I gave Alan the worst code (authors shall remain anonymous to
protect the guilty, but the project involved Mortgage Banking services...) I
have seen in over two decade of looking at SAS code, and his utility cleaned
it right up.
On Wed, Jun 10, 2009 at 4:30 PM, Richard Read Allen
<peakstat@wispertel.net>wrote:
> Try www.savian.net. I think Alan Churchill may have developed some
> utilities
> that may be able to help you.
>
> -Richard
>
> -----Original Message-----
> From: SAS(r) Discussion [mailto:SAS-L@LISTSERV.UGA.EDU] On Behalf Of Mary
> Sent: ...
Re: search SAS data set from SAS code> From: Rose
> Hi All,
> Suppose I have a sas permanent data set which was created
> early, I know
> the library path but I couldn't remember in which sas program code I
> created it. how can I search from so many sas program files in
> different folders and find it.
a problem familiar to all of us delayed-housekeeping folks.
Libname Libref '<directory-specification>';
DATA LibRef.DataSetName;
use your system utilities to search for the dir-spec
of your libref.
search: *.sas
containing text: <dir-spec>
once you have found the libname...