Dear All,
here is the problem regarding date format. the date variable is in character format and some values are in numbers and some values are in date format.
so how do i convert all in to one format.
i attached the data for your reference.
Date of Interview |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
9/1/1990 |
9/1/1990 |
9/1/1990 |
9/1/1990 |
9/1/1990 |
9/1/1990 |
9/1/1990 |
9/1/1990 |
9/1/1990 |
9/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
30/06/1990 |
30/06/1990 |
9/1/1990 |
9/1/1990 |
9/1/1990 |
9/1/1990 |
9/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
30/06/1990 |
30/06/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
30/06/1990 |
30/06/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
8/1/1990 |
28/03/1990 |
9/1/1990 |
9/1/1990 |
9/1/1990 |
9/1/1990 |
9/1/1990 |
30/06/1990 |
30/06/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
30/06/1990 |
30/06/1990 |
12/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
30/06/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
8/1/1990 |
8/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
30/06/1990 |
30/06/1990 |
10/1/1990 |
10/1/1990 |
30/06/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
30/06/1990 |
30/06/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
30/06/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
30/06/1990 |
30/06/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
8/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
10/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
1/7/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
11/1/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
30/06/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
12/1/1990 |
30/06/1990 |
30/06/1990 |
Can't see the problem in your attached dates, they are all in date format. So just input them...?
Hope the below code works..
data _null_;
set date;
new_date=input(date,yymmdd10.);
if not missing(new_date) then
final_date=new_date;
else
final_date=date;
put final_date=;
run;
data test;
input date_of_interview :$10.;
format final_date_of_interview date9.;
final_date_of_interview=input(date_of_interview,ddmmyy10.);
cards;
30/06/1990
30/06/1990
30/06/1990
30/06/1990
30/06/1990
30/06/1990
30/06/1990
30/06/1990
9/1/1990
9/1/1990
9/1/1990
9/1/1990
9/1/1990
9/1/1990
9/1/1990
9/1/1990
9/1/1990
9/1/1990
;
run;
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.
Use this tutorial as a handy guide to weigh the pros and cons of these commonly used machine learning algorithms.
Find more tutorials on the SAS Users YouTube channel.