/* Macro for importing data in SAS which is available in multiple sheets of a single excel file */
%macro dataload(sheet);
proc import out= &sheet datafile = 'location of excel file\filename.xlsx' dbms = XLSX replace; sheet = "&sheet"; getnames = yes; run;
%mend dataload; %dataload(Contract); %dataload(Instrument); %dataload(Protection); %dataload(Counterparty);
... View more