<?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 DATETIME format help in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/DATETIME-format-help/m-p/409268#M99971</link>
    <description>&lt;P&gt;&lt;BR /&gt;How to Query date which is in format datetime20. (table1) in the proc sql case statement (Joined two tables)&lt;/P&gt;&lt;P&gt;case&amp;nbsp;when&amp;nbsp;test.log =&amp;nbsp;"01MAY2015"d&amp;nbsp; then&amp;nbsp;'201505'&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Table 1 date format is datetime20.&lt;/P&gt;&lt;P&gt;Table 2 date format is yymmmdd10.&lt;/P&gt;</description>
    <pubDate>Tue, 31 Oct 2017 19:05:34 GMT</pubDate>
    <dc:creator>Kalai2008</dc:creator>
    <dc:date>2017-10-31T19:05:34Z</dc:date>
    <item>
      <title>DATETIME format help</title>
      <link>https://communities.sas.com/t5/SAS-Programming/DATETIME-format-help/m-p/409268#M99971</link>
      <description>&lt;P&gt;&lt;BR /&gt;How to Query date which is in format datetime20. (table1) in the proc sql case statement (Joined two tables)&lt;/P&gt;&lt;P&gt;case&amp;nbsp;when&amp;nbsp;test.log =&amp;nbsp;"01MAY2015"d&amp;nbsp; then&amp;nbsp;'201505'&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Table 1 date format is datetime20.&lt;/P&gt;&lt;P&gt;Table 2 date format is yymmmdd10.&lt;/P&gt;</description>
      <pubDate>Tue, 31 Oct 2017 19:05:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/DATETIME-format-help/m-p/409268#M99971</guid>
      <dc:creator>Kalai2008</dc:creator>
      <dc:date>2017-10-31T19:05:34Z</dc:date>
    </item>
    <item>
      <title>Re: DATETIME format help</title>
      <link>https://communities.sas.com/t5/SAS-Programming/DATETIME-format-help/m-p/409270#M99972</link>
      <description>Rather than if/then consider using an approriate format instead. 

Look at DATEPART to create a DATE variable from a DATETIME variable</description>
      <pubDate>Tue, 31 Oct 2017 19:17:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/DATETIME-format-help/m-p/409270#M99972</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2017-10-31T19:17:02Z</dc:date>
    </item>
    <item>
      <title>Re: DATETIME format help</title>
      <link>https://communities.sas.com/t5/SAS-Programming/DATETIME-format-help/m-p/409309#M99985</link>
      <description>&lt;P&gt;The date formats are only relevant in presentation of your data. But they do tell you what the numbers mean (seconds since 01JAN1960:00:00:00 or days since 01JAN1960. Internally they are stored as a number. But they are the same values no matter what date or datetime format is associated. As a consequence a date can always be queried using a date literal like '02NOV2017'd or a datetime like ' 02JAN2017:00:00:00'dt. If you want to compare a datetime to a date use the datepart() function: WHERE datepart(dtvar)='02NOV2017'd.&amp;nbsp; In a join that could be WHERE datepart(dtvar)=datevar.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hope this helps,&lt;/P&gt;
&lt;P&gt;- Jan.&lt;/P&gt;</description>
      <pubDate>Tue, 31 Oct 2017 22:45:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/DATETIME-format-help/m-p/409309#M99985</guid>
      <dc:creator>jklaverstijn</dc:creator>
      <dc:date>2017-10-31T22:45:27Z</dc:date>
    </item>
  </channel>
</rss>

