Hi, is there a way to insert date after "Date Extraction:" below,
Use a macro variable, and double quotes:
%let date = %sysfunc(today(),yymmdd10.);
proc odstext;
p "Source:"/ style=[color=blue fontsize=12pt fontfamily='Courier New' fontweight=bold];
list;
item "Master Database, Date Extraction: &date." / style=[fontsize=11pt fontfamily='Courier New'];
end;
run;
Hint: use single quotes in SAS only where explicitly needed, or if you need to prevent the resolution of macro triggers.
a macro variable for start?
%let date=%sysfunc(int('14mar2024'd),yymmdd10.);
proc odstext;
p 'Source:'/ style=[color=blue fontsize=12pt fontfamily='Courier New' fontweight=bold];
list;
item "Master Database, Date Extraction: &date." / style=[fontsize=11pt fontfamily='Courier New'];
end;
run;
Bart
Use a macro variable, and double quotes:
%let date = %sysfunc(today(),yymmdd10.);
proc odstext;
p "Source:"/ style=[color=blue fontsize=12pt fontfamily='Courier New' fontweight=bold];
list;
item "Master Database, Date Extraction: &date." / style=[fontsize=11pt fontfamily='Courier New'];
end;
run;
Hint: use single quotes in SAS only where explicitly needed, or if you need to prevent the resolution of macro triggers.
Save $250 on SAS Innovate and get a free advance copy of the new SAS For Dummies book! Use the code "SASforDummies" to register. Don't miss out, May 6-9, in Orlando, Florida.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.