Hello all,
kindly help me in converting the date values to ISO8601 format.
i have date values as :
TRTSTDT and TRENDT are NUMERIC type as below:
TRSTDT TRENDT
06DEC2007 20DEC2007
16JUN2009 30JUN2009
I want to convert them to CHARACTER variables as
RFSTDTC and RFENDTC to ISO8601 format,
Kindly help me.
Whn you say ISO 8601 Format, does that mean that 06DEC2007 becomes 20071206? 🙂
What did you try? SAS has a number of ISO formats.
https://support.sas.com/documentation/cdl/en/leforinforref/64790/HTML/default/viewer.htm#n0p2fmevfgj...
RFSTDTC = put(TRTSTDT,B8601DA8.);
Of course you could also just use the YYMMDDN format.
It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.
Latest Updates
SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.
Find more tutorials on the SAS Users YouTube channel.