Good Evening Team,
I am assigning value to one macro variable but while using that macro variable value I am getting error below. Can you please help.
ERROR: Attribute '202206' not found
%put yearmonth --> &yrmonth;
yearmonth --> 202206
Regards
Kajal
proc sql; select max(yearmonth) into : yrmonth from source_data; quit; proc sql; delete * from target_data where yearmonth= &yrmonth.; quit;
Thank you for your kind response I was able to resolve the issue.
Regards
Kajal
Good Evening Team,
I am assigning value to one macro variable but while using that macro variable value I am getting error below. Can you please help.
Regards
Kajal
proc sql; select max(yearmonth) into : yrmonth from source_data; quit; proc sql; delete * from target_data where yearmonth= &yrmonth.; quit;
ERROR: Attribute '202206' not found
%put yearmonth --> &yrmonth;
yearmonth --> 202206
There's no asterisk in the SQL DELETE statement:
proc sql;
delete from target_data
where yearmonth= &yrmonth.;
quit;
Thank you for your kind response I was able to resolve the issue.
Regards
Kajal
April 27 – 30 | Gaylord Texan | Grapevine, Texas
Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and save with the early bird rate—just $795!
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.