Hello team,
What does format find $15. mean in SAS?
Please advise me.
Regards,
blue blue
format find $15.;
This is a FORMAT Statement, and it assigns the $15. format to the variable find.
If this variable is not present in any of the input datasets, it will be defined as character with a length of 15.
If the goal is to actually define the variable as mentioned above, a LENGTH statement would be more appropriate.
Hello team,
I searched for it and I couldn't find it.
Regards,
blueblue
If a word appears at the beginning of a data step statement without a following equal sign, then it has to be a Data Step Statement.
Bookmark the link, and use it as a starting point for similar inquiries.
Please post the code where it is used, so we can explain it for you in context.
data out.mydata; merge thisdata(in=a) thatdata(in=b); by hkey; format find $15.; if a and b then Find = 'Both'; if a and not b then Find = 'not_in_thisdata' if a then output; run;
format find $15.;
This is a FORMAT Statement, and it assigns the $15. format to the variable find.
If this variable is not present in any of the input datasets, it will be defined as character with a length of 15.
If the goal is to actually define the variable as mentioned above, a LENGTH statement would be more appropriate.
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 lock in 2025 pricing—just $495!
Still thinking about your presentation idea? The submission deadline has been extended to Friday, Nov. 14, at 11:59 p.m. ET.
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.