Hi, all:
I saw several codes written from previous programmer. Could someone let me know what they are refering to? Thanks.
Y
%including "file-specification"/source2;
%rename (uned., _3);
%including "file-specification"/source2;
%state (uned., _4);
%including "file-specification"/source2;
%report (uned., _5);
I specify the %including code:
%including "\\test\_3_rename.sas"/source2;
%rename (uned., _3);
%including "\\test\_4_state.sas"/source2;
%state (uned., _4);
%including "\\test\_5_report.sas"/source2;
%report (uned., _5);
I don't think that is the exact code is it. The first:
%including "file-specification"/source2;
Is not correct, correct syntax is:
%include "file-specification" / source2;
This loads the given text file and inserts the text at the point of include.
The other three are calls to user built macros. As I am not on your system, can't see any of it, I cannot state anything other than that.
Yes. I apologize my typo. It's %include.
You should post the real code you have questions about. "%including" is not valid SAS syntax.
That said, %include tells SAS to fetch the file and place its contents where the %include was.
The other lines seem to call macros from those files.
@Jagadishkatam wrote:
But i wonder why the %include statemnet has the sas program name as _3_rename.sas and %macro call name is %rename I am expecting the %include should refer to the rename.sas programs file.
@Jagadishkatam I've seen file naming conventions like that when they were used to indicate the Order that scipts or programs should be run. I'm not saying it's a good practice but I've seen that.
Hi,
If %rename is the macro call which is being referred in the %include statement. It shouldn't be use semicolom, it should be just
%rename
Am I right?
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
Need to connect to databases in SAS Viya? SAS’ David Ghan shows you two methods – via SAS/ACCESS LIBNAME and SAS Data Connector SASLIBS – in this video.
Find more tutorials on the SAS Users YouTube channel.