Hi Everyone,
I have one question like we can list out the sas dataset their location and as well as library using SAS dictionary object, but would it possible to list all program which are calling perticular library? Like suppose i have library TEST in which 10 dataset is there, so can i get list of .sas file in which my dataset present in that libary is getting called? Also same about autocall library for macro, can we list all .sas program based on the autocall library ? imean if we just have a library name? Please Assist me for the same. Thanks in Advanced.
Regards,
Tushar Jagtap.
If you are using Base to create those .sas files, there are no out-of-the-box tool in SAS for this. One SAS tool that can get you half way is the SAS code analyzer.
Basic OS tools may help, such as grep (UNIX) and FindStr (Windows).
You could if you like create some SAS program that reads through all SAS-programs.
Either way, it could be quite complex. If your lucky you can find some sample on the Internet.
Thanks LinusH for your quick reply.
Basically as per my requirement i found this similar functionality in SAS DI that is what we called Impact Analysis. So basically what i was doing to implement the same using BASE SAS Code. but its look like i need to write some SAS-Unix wrapper programming. Initially i had the same thought in my mind using some OS specific functionality. Then i thought before implement lets throw this discussion on SAS community portal, looking for wether any Proc present in Base SAS for implementing kind of funcitonality. Anyway Thanks a lot again.
Regrads,
Tushar J.
If your SAS programs are running in batch, consider to import them to DI Studio, and then you could make use of the Analyze capabilities there (for this, the SAS Code Importer usually works fine).
Thanks LinusH,
I will try that option too...
Regards,
Tushar J
Hi,
you can make use of dopen, dnum & dread functions if you do not want use OS commands
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 16. Read more here about why you should contribute and what is in it for you!
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Select SAS Training centers are offering in-person courses. View upcoming courses for: