Hello,
I have years appear as 1990, 1991, 1992 and I need them to appear as 19900101, 19910101, 19920101
How would you go about doing this conversion?
Please use MDY function and assign 1 for date and month-
data have;
do year=1990 to 2000;
output;
end;
run;
data want;
set have;
date=mdy(1,1,year);
format date yymmdd10.;
run;
I did and now the formatting is an issue.
I got long numbers that I think are SAS date values. What format to use to have the dates appear as YYYY0101?
THANK YOU THANK YOU THANK YOU!!!!!
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.