Created
August 29, 2017 15:40
-
-
Save statgeek/1a8e008ecc2fe47e03c3d0022c361e78 to your computer and use it in GitHub Desktop.
SAS - loop through macro variables and resolve
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*Demo to show how to loop through a list of macro variables*/ | |
proc sql noprint; | |
select name into :name1- | |
from sashelp.class; | |
quit; | |
%macro demo; | |
%do i=1 %to 10; | |
%put name&i=&&name&i; | |
%end; | |
%mend; | |
%demo; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment