<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Date conversion to iso 8601 in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Date-conversion-to-iso-8601/m-p/511350#M137595</link>
    <description>&lt;P&gt;what syntax can i use to convert this date format "14MAY2008:00:00:00" to "2008-05-14T00:00" to iso 8601 format ?&lt;/P&gt;</description>
    <pubDate>Thu, 08 Nov 2018 12:27:41 GMT</pubDate>
    <dc:creator>Aayushi_17</dc:creator>
    <dc:date>2018-11-08T12:27:41Z</dc:date>
    <item>
      <title>Date conversion to iso 8601</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Date-conversion-to-iso-8601/m-p/511350#M137595</link>
      <description>&lt;P&gt;what syntax can i use to convert this date format "14MAY2008:00:00:00" to "2008-05-14T00:00" to iso 8601 format ?&lt;/P&gt;</description>
      <pubDate>Thu, 08 Nov 2018 12:27:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Date-conversion-to-iso-8601/m-p/511350#M137595</guid>
      <dc:creator>Aayushi_17</dc:creator>
      <dc:date>2018-11-08T12:27:41Z</dc:date>
    </item>
    <item>
      <title>Re: Date conversion to iso 8601</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Date-conversion-to-iso-8601/m-p/511353#M137596</link>
      <description>&lt;P&gt;All formats and informats are detailed here:&lt;/P&gt;
&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/lrdict/64316/HTML/default/viewer.htm#a001263753.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/lrdict/64316/HTML/default/viewer.htm#a001263753.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I would say the first is a datetime informat, the wanted result is an e8601dt format.&lt;/P&gt;</description>
      <pubDate>Thu, 08 Nov 2018 12:36:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Date-conversion-to-iso-8601/m-p/511353#M137596</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2018-11-08T12:36:44Z</dc:date>
    </item>
    <item>
      <title>Re: Date conversion to iso 8601</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Date-conversion-to-iso-8601/m-p/511379#M137607</link>
      <description>&lt;P&gt;Are you missing "Seconds" in your required format. Is it supposed to be "&amp;nbsp;&lt;SPAN&gt;2008-05-14T00:00:00 ". If you don't want the seconds to be included then, then only option will be storing the values as charactes because any 8601 ISO format includes seconds.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;If you require seconds too, then use &lt;STRONG&gt;E8601DT19.&lt;/STRONG&gt; format if the values are stored as actual date time&amp;nbsp;values. If they are stored as character values then you may need to convert them using INPUT() function.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;/* If actual values are as character */
data test;
format date E8601DT20.;
date_Char='14MAY2008:00:00:00';
date=INPUT(date_Char,datetime.);

run;

/* Stored as actual date */
data test;
format date E8601DT20.;
date='14MAY2008:00:00:00'dt;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 09 Nov 2018 13:14:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Date-conversion-to-iso-8601/m-p/511379#M137607</guid>
      <dc:creator>SuryaKiran</dc:creator>
      <dc:date>2018-11-09T13:14:32Z</dc:date>
    </item>
    <item>
      <title>Re: Date conversion to iso 8601</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Date-conversion-to-iso-8601/m-p/511645#M137713</link>
      <description>&lt;P&gt;Thank you so much all&lt;/P&gt;</description>
      <pubDate>Fri, 09 Nov 2018 12:12:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Date-conversion-to-iso-8601/m-p/511645#M137713</guid>
      <dc:creator>Aayushi_17</dc:creator>
      <dc:date>2018-11-09T12:12:46Z</dc:date>
    </item>
  </channel>
</rss>

