🔒 This topic is solved and locked.
Need further help from the community? Please
sign in and ask a new question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Posted 05-20-2019 04:55 AM
(17186 views)
Hello,
Do you know if it exists a DATETIME format such like YYYY-MM-DDThh:mm:ss (note the 'T' between time and date),
and if not how to create this format with functions.
Thank you,
Regards,
Hugo_B.
1 ACCEPTED SOLUTION
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
There is (see Maxim 8 🙂 ).
It is E8601DT19.
29 data _null_; 30 now = datetime(); 31 format now e8601dt19.; 32 put now=; 33 run; now=2019-05-20T11:03:22
2 REPLIES 2
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
proc format;
picture dtpic
other='%Y-%0m-%0dT%0H:%0M:%0S' (datatype=datetime);
run;
data test;
datetime='25dec2000 00:00:00'dt;
format datetime dtpic.;
run;
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
There is (see Maxim 8 🙂 ).
It is E8601DT19.
29 data _null_; 30 now = datetime(); 31 format now e8601dt19.; 32 put now=; 33 run; now=2019-05-20T11:03:22