<?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: Add Date Field mmddyy8. to dataset and update from Char Date field in SAS Studio</title>
    <link>https://communities.sas.com/t5/SAS-Studio/Add-Date-Field-mmddyy8-to-dataset-and-update-from-Char-Date/m-p/284071#M801</link>
    <description>&lt;P&gt;Your statement would always create a numeric variable (even if you need to adjust it according to Reeza's suggestion, the same applies).&amp;nbsp; If you are getting a character variable as the result, it is because SOURCE_DATE_DTE already exists (as a character variable) within the incoming data set ALL_MONTH_LOANS_DETAIL.&amp;nbsp; It should be dropped from the input.&lt;/P&gt;</description>
    <pubDate>Wed, 13 Jul 2016 15:06:43 GMT</pubDate>
    <dc:creator>Astounding</dc:creator>
    <dc:date>2016-07-13T15:06:43Z</dc:date>
    <item>
      <title>Add Date Field mmddyy8. to dataset and update from Char Date field</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Add-Date-Field-mmddyy8-to-dataset-and-update-from-Char-Date/m-p/284025#M798</link>
      <description>&lt;P&gt;I have a dataset with a character date field (Source_Date Char(35)) with&amp;nbsp;data in this format, "mmddyy" (no slashes)&amp;nbsp;.&amp;nbsp; I want to:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1.&amp;nbsp; &lt;STRONG&gt;Add&lt;/STRONG&gt; a new date field, &amp;nbsp;&lt;STRONG&gt;"Source_Date_dte mmddyy8."&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;2.&amp;nbsp; &lt;STRONG&gt;Update&lt;/STRONG&gt; the new Source_Date_dte field with the date value from the Source_Date.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;For Example:&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; New field value&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;060116-------------------&amp;gt; 06/01/16&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Here is my code attempt:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;data&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; ALL_MONTHS_LOAN_DETAIL_new;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;set&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt; ALL_MONTHS_LOAN_DETAIL;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;Source_Date_dte=input(Source_Date, 6&lt;/FONT&gt;&lt;/FONT&gt;&lt;STRONG&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;);&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;format&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt; Source_Date_dte &lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;&lt;FONT color="#008080" face="Courier New" size="3"&gt;mmddyy8.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;run:&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;This code produces a new field Source_Date_dte &lt;/STRONG&gt;Character&lt;STRONG&gt; 15 with format $MDDYY10&amp;nbsp;and no data populated in the new field.&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;Help Please&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&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>Wed, 13 Jul 2016 13:29:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Add-Date-Field-mmddyy8-to-dataset-and-update-from-Char-Date/m-p/284025#M798</guid>
      <dc:creator>Kody_devl</dc:creator>
      <dc:date>2016-07-13T13:29:04Z</dc:date>
    </item>
    <item>
      <title>Re: Add Date Field mmddyy8. to dataset and update from Char Date field</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Add-Date-Field-mmddyy8-to-dataset-and-update-from-Char-Date/m-p/284029#M799</link>
      <description>&lt;P&gt;Use the appropriate date informat. In your input function try mmddyy6. as the informat rather than 6.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 13 Jul 2016 13:40:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Add-Date-Field-mmddyy8-to-dataset-and-update-from-Char-Date/m-p/284029#M799</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-07-13T13:40:19Z</dc:date>
    </item>
    <item>
      <title>Re: Add Date Field mmddyy8. to dataset and update from Char Date field</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Add-Date-Field-mmddyy8-to-dataset-and-update-from-Char-Date/m-p/284033#M800</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Perfect!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you!&lt;/P&gt;</description>
      <pubDate>Wed, 13 Jul 2016 13:50:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Add-Date-Field-mmddyy8-to-dataset-and-update-from-Char-Date/m-p/284033#M800</guid>
      <dc:creator>Kody_devl</dc:creator>
      <dc:date>2016-07-13T13:50:13Z</dc:date>
    </item>
    <item>
      <title>Re: Add Date Field mmddyy8. to dataset and update from Char Date field</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Add-Date-Field-mmddyy8-to-dataset-and-update-from-Char-Date/m-p/284071#M801</link>
      <description>&lt;P&gt;Your statement would always create a numeric variable (even if you need to adjust it according to Reeza's suggestion, the same applies).&amp;nbsp; If you are getting a character variable as the result, it is because SOURCE_DATE_DTE already exists (as a character variable) within the incoming data set ALL_MONTH_LOANS_DETAIL.&amp;nbsp; It should be dropped from the input.&lt;/P&gt;</description>
      <pubDate>Wed, 13 Jul 2016 15:06:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Add-Date-Field-mmddyy8-to-dataset-and-update-from-Char-Date/m-p/284071#M801</guid>
      <dc:creator>Astounding</dc:creator>
      <dc:date>2016-07-13T15:06:43Z</dc:date>
    </item>
  </channel>
</rss>

