Thanks for your help everyone.
I'll be more specific, so maybe you will understand better why i am asking those questions, and which direction im taking.
I work for a company with a lots of programs. Suppose we need to make some changes to a file such as:
W:\TarificationFiles\2007\WesternCanada.xls
And this file is imported by SAS programs.
Because of the modifications, we need to make sure all programs using this file will still be running correctly. If i search for the file in the programs' code, it might be tricky because it can be stored in a macro var, or imported by a macro, etc.
Option 1
So, in a perfect world, i would put an option in the sas program such as
"analyse_input_output_files" and when SAS would run the program "MyProg.sas", it
would create a table such as:
Program Input_Output Filename
------------------------------------------------------------------
MyProg IN W:\TarificationFiles\2007\WesternCanada.xls
MyProg OUT W:\Results\2007\Results.xls
MyProg OUT W:\Results\2007\Validation.xls
Option 2:
I run a program, either Java/C/SAS, or anything. This program will read MyProg.sas, resolve macro code, and find out which files are used. This option is tough, but is good because MyProg.sas doesnt needs to be run. (of course some problems might appear if some macro vars are defined in an sql statement or in a data step)
Option 3:
MFile option is used. The automatic launcher that launches all programs on daily/weekly schedules set this option for every program. Then, i can analyze the logs with another program. The problem with this option is that the program needs to be run.
So.
I dont see how to do anything like option 1, unless i was working for SAS.
Option 2 could be nice, but i would need to find a way to resolve macro stuff without spending years to create a macro compiler 🙂
Option 3 is the one i can do pretty easily, but programs needs to be executed. Not so great when programs takes hours to run...
I guess i should have given those details in my first post 🙂
... View more