Hi,
I am using SAS EG for my project. I have written following code to resolve week value which is working fine in SAS 9.1. But it is not working in SAS EG. Please help with you suggestions.
data dummy2;
set outdata.&fiscal_map.;
if start_dt le '22Dec2014'd and '22Dec2014'd le end_dt then do;
call symput('week_start', week_no);
end;
run;
%put &week_start;
Appreciate your help.
Thanks
Your code should work in EG too.
What warning or error messages do you get?
Make sure, your if condition is satisfied. Put a putlog 'CONDITION IS TRUE'; statement above call symput. Do you see this 'CONDITION IS TRUE' message in the log?
Please describe what "not working" means. Error? Unexpected value? No output/ blank value but no error?
It is possible that you expect one value but more than one record satisfies your if condition. You would get the value associated with the LAST record where the condition is true.
Don't miss out on SAS Innovate - Register now for the FREE Livestream!
Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.
What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.
Find more tutorials on the SAS Users YouTube channel.