I need to call two macro variables which are created within another macro. However, I got the following warning message saying Apparent symbolic reference not resovled. What I am trying to do is to create a macro variable for the total count of the item and put the number of count in the log. %MACRO C(VAR,COUNT_VAR,FILTER); PROC SQL ; SELECT COUNT(&VAR) INTO: &COUNT_VAR FROM table2 WHERE &FILTER; QUIT; %MEND; %C(Unsuccessful_item, COUNT_U,Unsuccessful_item EQ "Yes"); %C(Late_item,COUNT_L,Late_item EQ "Yes"); %PUT &COUNT_U &COUNT_L; WARNING: Apparent symbolic reference COUNT_U not resolved. WARNING: Apparent symbolic reference COUNT_L not resolved. If I do this in two separate steps, I am able to run through. However, in real work situation, I need to do this in macro, can anyone advice. Thanks. PROC SQL ; SELECT COUNT(Unsuccessful_item) INTO: COUNT_U FROM table2 WHERE Unsuccessful_item EQ "Yes"; QUIT; PROC SQL ; SELECT COUNT(Late_item) INTO: COUNT_L FROM table2 WHERE Late_item EQ "Yes"; QUIT; %PUT &COUNT_U &COUNT_L; 38 %PUT &COUNT_U &COUNT_L; SYMBOLGEN: Macro variable COUNT_U resolves to 13 SYMBOLGEN: Macro variable COUNT_L resolves to 25 13 25
... View more