<?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: Need to convert character mm/dd/yyyy to SAS date and time in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Need-to-convert-character-mm-dd-yyyy-to-SAS-date-and-time-in/m-p/281539#M19341</link>
    <description>&lt;P&gt;Will that tool let you type an actualy function? &amp;nbsp;If your variable with the characters in is named CHARVAR then this assignment statement will make the variable DATETIME have the equivalent datetime value.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;datetime=dhms(input(charvar,'MMDDYY10.'),,,0);
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Thu, 30 Jun 2016 18:38:44 GMT</pubDate>
    <dc:creator>Tom</dc:creator>
    <dc:date>2016-06-30T18:38:44Z</dc:date>
    <item>
      <title>Need to convert character mm/dd/yyyy to SAS date and time in Query Builder</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Need-to-convert-character-mm-dd-yyyy-to-SAS-date-and-time-in/m-p/281535#M19340</link>
      <description>&lt;P&gt;Can this be done in the advanced expression calculation?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Example data to convert from char to SAS date:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;02/12/2016 to 12FEB2016:00:00:00&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jun 2016 20:42:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Need-to-convert-character-mm-dd-yyyy-to-SAS-date-and-time-in/m-p/281535#M19340</guid>
      <dc:creator>carmendee</dc:creator>
      <dc:date>2016-06-30T20:42:04Z</dc:date>
    </item>
    <item>
      <title>Re: Need to convert character mm/dd/yyyy to SAS date and time</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Need-to-convert-character-mm-dd-yyyy-to-SAS-date-and-time-in/m-p/281539#M19341</link>
      <description>&lt;P&gt;Will that tool let you type an actualy function? &amp;nbsp;If your variable with the characters in is named CHARVAR then this assignment statement will make the variable DATETIME have the equivalent datetime value.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;datetime=dhms(input(charvar,'MMDDYY10.'),,,0);
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 30 Jun 2016 18:38:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Need-to-convert-character-mm-dd-yyyy-to-SAS-date-and-time-in/m-p/281539#M19341</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2016-06-30T18:38:44Z</dc:date>
    </item>
    <item>
      <title>Re: Need to convert character mm/dd/yyyy to SAS date and time in Query Builder</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Need-to-convert-character-mm-dd-yyyy-to-SAS-date-and-time-in/m-p/281563#M19342</link>
      <description>&lt;P&gt;Yes,&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/159"&gt;@Tom﻿&lt;/a&gt;&amp;nbsp;is correct. &amp;nbsp;The Advanced Expression window allows this:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;dhms(input(t1.charvar,'MMDDYY10.'),,,0)&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Looks like this in your window:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/3867iC068701750E151FB/image-size/original?v=v2&amp;amp;px=-1" border="0" alt="ae.png" title="ae.png" /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jun 2016 20:42:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Need-to-convert-character-mm-dd-yyyy-to-SAS-date-and-time-in/m-p/281563#M19342</guid>
      <dc:creator>ChrisHemedinger</dc:creator>
      <dc:date>2016-06-30T20:42:28Z</dc:date>
    </item>
    <item>
      <title>Re: Need to convert character mm/dd/yyyy to SAS date and time in Query Builder</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Need-to-convert-character-mm-dd-yyyy-to-SAS-date-and-time-in/m-p/281570#M19343</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/4"&gt;@ChrisHemedinger﻿&lt;/a&gt;&amp;nbsp;Are the quotes required around the format? I think it might be like the following:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;dhms(input(t1.charvar, MMDDYY10.),,,0)&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jun 2016 21:24:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Need-to-convert-character-mm-dd-yyyy-to-SAS-date-and-time-in/m-p/281570#M19343</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-06-30T21:24:53Z</dc:date>
    </item>
    <item>
      <title>Re: Need to convert character mm/dd/yyyy to SAS date and time in Query Builder</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Need-to-convert-character-mm-dd-yyyy-to-SAS-date-and-time-in/m-p/281583#M19345</link>
      <description>&lt;P&gt;With the INPUT() functions you do not want the quotes around the format since the second argument is a format.&lt;/P&gt;
&lt;P&gt;But&amp;nbsp;the INPUTN() function , or the INPUTC() function, take an expression for the second argument so you do need the quotes.&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jun 2016 23:24:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Need-to-convert-character-mm-dd-yyyy-to-SAS-date-and-time-in/m-p/281583#M19345</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2016-06-30T23:24:49Z</dc:date>
    </item>
    <item>
      <title>Re: Need to convert character mm/dd/yyyy to SAS date and time in Query Builder</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Need-to-convert-character-mm-dd-yyyy-to-SAS-date-and-time-in/m-p/282421#M19374</link>
      <description>&lt;P&gt;This worked.&amp;nbsp; I had to add DATETIME20 to the format under "Modify additional options" in Enterprise Guide.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks all!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 06 Jul 2016 13:49:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Need-to-convert-character-mm-dd-yyyy-to-SAS-date-and-time-in/m-p/282421#M19374</guid>
      <dc:creator>carmendee</dc:creator>
      <dc:date>2016-07-06T13:49:35Z</dc:date>
    </item>
  </channel>
</rss>

