Viewing the Values of All Current Macro Variables
When developing or debugging a SAS application, it is often useful to check the values that have been assigned to Macro variables.
The easiest way to do this is to simply use the following command:
%put _ALL_;
This will list the current value of every macro variable within the SAS log.
In addition to _ALL_ you could use any of the following:
- _USER_ to list only user defined macro variables;
- _AUTOMATIC_ to list those defined by the SAS system;
- _GLOBAL_ to list all session wide macro variables (global symbol table);
- _LOCAL_ to list those macro variables local to the executing macro.
For more information on using the SAS macro language, view the SAS help or visit the SAS support site at www.support.sas.com.