I'm getting the error below when trying to use a text defined prompt variable is SAS EG and Stored Process. I tried a few methods to make the value usable but no luck so far. Any suggestion on how to fix this issue?
Prompt/variable Assignment
%let STRUCTURE = 4451227E;
143 WHERE t1.OVRHD_STRCTUR_NO IN (&Structure) NOTE: Line generated by the macro variable "STRUCTURE". The SAS System 143 4747487E _ 22 202 ERROR 22-322: Syntax error, expecting one of the following: a numeric constant, a datetime constant, a missing value, ), ',', -, :. ERROR 202-322: The option or parameter is not recognized and will be ignored.
Since your use of &Structure is not enclosed in quotes then it is not treated as a character value.
Try
WHERE t1.OVRHD_STRCTUR_NO IN ("&Structure")
so the prompt is treated as text.
Since your use of &Structure is not enclosed in quotes then it is not treated as a character value.
Try
WHERE t1.OVRHD_STRCTUR_NO IN ("&Structure")
so the prompt is treated as text.
Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!
Check out this tutorial series to learn how to build your own steps in SAS Studio.
Find more tutorials on the SAS Users YouTube channel.
Ready to level-up your skills? Choose your own adventure.