01-26-2013 10:31 PM
Can i have more macro codes written within one and then by callin the main one i can execute all?
Also,i have a dataset out of each i am supposed to run 10 queries.Can I write a macro that would export the results of all these 10 queries into one workbook of excel?
Not all of the 10 queries have the same column names.And if macro cant,can i do the same then without macro?
I am need to have the results of all the queries on one workbook so i can easily populate some tables in excel
01-26-2013 11:37 PM
A macro can call anything you want it to.
%macro big ;
Look at using ODS TAGSETS.EXCELXP to generate output into multiple sheets of an excel file.
01-28-2013 12:41 AM
Yes you can, but you'll have different tables is all, they won't stack up.
ods tagsets.excelxp file="c:\temp\test.xls";
proc print data=sashelp.class;
proc print data=sashelp.cars;
ods tagsets.excelxp close;