Hi community,
In the given table few of dates are not convert to the actual column pls help me to resolve it.
data dos;
set proj.saswrk;
diab_date = input(strip(diab_dateonset),mmddyy10.);
format diab_date mmddyy10.;
run;
Diab_dateonset - varchar datatype
Diab_dateonset | diab_date |
14/03/2009 | . |
21/11/1992 | . |
. | |
. | |
. | |
09/10/2006 | 09/10/2006 |
. | |
. | |
07/08/2010 | 07/08/2010 |
14/08/2009 | . |
15/03/2012 | . |
. | |
25/04/2013 | . |
09/12/2009 | 09/12/2009 |
. | |
08/08/2015 | 08/08/2015 |
You want ddmmyy format and informat.
You can't use format or informat mmddyy because some of your date values begin with 14 or 25 and there's no month 14 or 25.
You want ddmmyy format and informat.
You can't use format or informat mmddyy because some of your date values begin with 14 or 25 and there's no month 14 or 25.
Ohw !...
Thank you buddy!
@Sathish_jammy Please mark @PaigeMiller answer as the solution, so others know this is solved.
Sorry!
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
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.