rsubmit cwait=no cmacvar=done; proc sort data=permdata.standard(keep=fname lname major tgpa gender) out=honor_graduates(where=(tgpa>3.5)); by gender; run; title 'Male and Female Honor Graduates'; proc print; by gender; run; endrsubmit; %macro get_results_when_complete; %if &done=0 %then %do; %put Remote submit complete, issuing "rget" to get the results.; rget; %end; %else %do; %put Remote submit not complete.; %put Issue: "%nrstr(%%)get_results_when_complete" later.; %end; %mend; %get_results_when_complete; /* continue with client session processing */ /* issue again if RSUBMIT not complete */ %get_results_when_complete;