<?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 Re: date format in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491081#M128690</link>
    <description>Have you tried what I gave you?&lt;BR /&gt;</description>
    <pubDate>Thu, 30 Aug 2018 04:42:31 GMT</pubDate>
    <dc:creator>ChrisNZ</dc:creator>
    <dc:date>2018-08-30T04:42:31Z</dc:date>
    <item>
      <title>date format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491074#M128685</link>
      <description>&lt;P&gt;how to convert&lt;STRONG&gt; is8601dt.&amp;nbsp;numeric&amp;nbsp;&lt;/STRONG&gt; format to&amp;nbsp;&lt;STRONG&gt;is8601dt character&lt;/STRONG&gt;&amp;nbsp;format&lt;/P&gt;</description>
      <pubDate>Thu, 30 Aug 2018 04:23:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491074#M128685</guid>
      <dc:creator>KalaBhairava</dc:creator>
      <dc:date>2018-08-30T04:23:34Z</dc:date>
    </item>
    <item>
      <title>Re: date format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491079#M128688</link>
      <description>&lt;P&gt;What on earth is&amp;nbsp;&lt;STRONG&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;is8601dt.&amp;nbsp;numeric&amp;nbsp;&lt;/STRONG&gt;&lt;SPAN&gt;&amp;nbsp;format?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Is your&amp;nbsp;numeric variable a SAS date time?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;in that case&amp;nbsp;&amp;nbsp;&lt;FONT face="courier new,courier"&gt;CHARVAR=put(MYDATETIME,is8601dt.)&amp;nbsp;&lt;/FONT&gt; may be want you want.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If not, show what you have (variable type, format and value) and what you want.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 30 Aug 2018 04:35:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491079#M128688</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2018-08-30T04:35:08Z</dc:date>
    </item>
    <item>
      <title>Re: date format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491080#M128689</link>
      <description>&lt;P&gt;My variable format is in&amp;nbsp;IS8601DT19. (&lt;STRONG&gt;neumeric&lt;/STRONG&gt;) but i want to convert it into &lt;SPAN&gt;IS8601DT19&amp;nbsp;&lt;/SPAN&gt;&lt;STRONG&gt;chracter&lt;/STRONG&gt;&amp;nbsp; for SDTM&lt;/P&gt;</description>
      <pubDate>Thu, 30 Aug 2018 04:40:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491080#M128689</guid>
      <dc:creator>KalaBhairava</dc:creator>
      <dc:date>2018-08-30T04:40:37Z</dc:date>
    </item>
    <item>
      <title>Re: date format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491081#M128690</link>
      <description>Have you tried what I gave you?&lt;BR /&gt;</description>
      <pubDate>Thu, 30 Aug 2018 04:42:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491081#M128690</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2018-08-30T04:42:31Z</dc:date>
    </item>
    <item>
      <title>Re: date format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491082#M128691</link>
      <description>Yes ,but $19 format is coming.</description>
      <pubDate>Thu, 30 Aug 2018 04:46:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491082#M128691</guid>
      <dc:creator>KalaBhairava</dc:creator>
      <dc:date>2018-08-30T04:46:59Z</dc:date>
    </item>
    <item>
      <title>Re: date format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491085#M128694</link>
      <description>&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;Show what you have (variable type, format and value) and what you want.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 30 Aug 2018 04:52:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491085#M128694</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2018-08-30T04:52:21Z</dc:date>
    </item>
    <item>
      <title>Re: date format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491086#M128695</link>
      <description>&lt;P&gt;Please supply example data and be more specific. As is, your question makes no sense.&lt;/P&gt;
&lt;P&gt;If a datetime value is already formatted with a e8601 format, it will always display as such and be written to external files as such.&lt;/P&gt;
&lt;P&gt;Converting it to character serves no purpose and only deprives you of the use of all the SAS date- and datetime- related tools.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 30 Aug 2018 04:56:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491086#M128695</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2018-08-30T04:56:56Z</dc:date>
    </item>
    <item>
      <title>Re: date format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491125#M128723</link>
      <description>&lt;P&gt;Do you mean ISO dates, as is used in CDISC for instance?&amp;nbsp; If so then:&lt;/P&gt;
&lt;PRE&gt;data want;
  datetime_date="01JAN2018 01:12"dt;
  iso_date=datetime_date;
  string_date=put(datetime_date,e8601dt.);
  format datetime_date datetime. iso_date e8601dt.;
run;&lt;/PRE&gt;
&lt;P&gt;This shows a datetime variable, which can be formatted to ISO, and a character version.&lt;/P&gt;</description>
      <pubDate>Thu, 30 Aug 2018 08:06:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491125#M128723</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2018-08-30T08:06:54Z</dc:date>
    </item>
    <item>
      <title>Re: date format</title>
      <link>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491361#M128837</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/204061"&gt;@KalaBhairava&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;Yes ,but $19 format is coming.&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;You specifically requested a character value. Unless you&amp;nbsp; assign a custom format they are ALL going to have a $x. format.&lt;/P&gt;
&lt;P&gt;Or is the actual length the question? The length would depend on the width specified for the format when using the PUT function.&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Courier New"&gt;CHARVAR=put(MYDATETIME,is8601dt.)&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;Defaults to a length of 19 if not specified. If you want longer result then use IS8601DT26. (maximum length for the format is 26) if you expect/need decimal portions then IS8601DT26.d&amp;nbsp;&amp;nbsp; where d can range from 0 to 6.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 30 Aug 2018 17:56:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/date-format/m-p/491361#M128837</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2018-08-30T17:56:58Z</dc:date>
    </item>
  </channel>
</rss>

