04-14-2012 11:18 AM
is this legal?
proc print data=sashelp.cars;
I tested it, it returns the result, but I don't know if it the right way to do?
04-14-2012 12:31 PM
Yes, the only restriction is that you include complete statements, not partial statements. You cannot do
if x > 0 then %include 'myFile.sas";
That doesn't work. But you can do:
if x>0 then do;
But you must remember that the inclusion will occur even if x <= 0. The do block will not be executed, but the code from myFile.sas will be included.
Hope that helps.