SYSPBUFF
to define a macro
that accepts a varying number of parameters each time you call it.
%macro choice(status); data fees; set sasuser.all; %if &status=PAID %then %do; where paid='Y'; keep student_name course_code begin_date totalfee; %end; %else %do; where paid='N'; keep student_name course_code begin_date totalfee latechg; latechg=fee*1.10; %end; /* add local surcharge */ if location='Boston' then totalfee=fee*1.06; else if location='Seattle' then totalfee=fee*1.025; else if location='Dallas' then totalfee=fee*1.05; run; %mend choice;
3.145.202.27