SAS Tip: Use the SOURCE2 Option with %include to Get a Detailed Log (Daily tip for 2025-Sep-26)


You can use the SOURCE2 system option to get more details in the log for files that are run with %include:

options source2;
%include 'C:\my SAS files\sample program.sas';

To disable this option: options nosource2; Or, for even more control, you can temporarily enable the option for a specific %include call:

%include 'C:\my SAS files\sample program.sas' /source2;

Thanks to Otterm1 for sharing this tip

 

 

 

 

 

 

READ this complete tip   Visit a random SAS tip

Start a topic
About these Tips
A "SAS tip" is a basic unit of information exchange between SAS users. The tips on this board come from sasCommunity.org, from SAS user conferences, from SAS blogs, and from freelance contributions from SAS users like you. We hope that you're able to always learn something new here!


» How you can contribute


Tip-o-meter: 65 tips