Hi all, here is my script below: %let list=; %macro fix(suffix); proc sql noprint; select name into :vars separated by ' ' from dictionary.columns where upcase(libname)=upcase('work') and upcase(memname)=upcase('RN_LIST') and index(name,upcase("&suffix")) ge 1; quit; %let list=&list &vars; %put &list; %mend fix; %fix('2019'); %fix('2018'); %fix('2017'); I am trying to take variables from the past 3 years. however it keeps duplicating '2019' could someone please help to fix it?
... View more