<?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: converting date of birth to required spec in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/converting-date-of-birth-to-required-spec/m-p/298996#M60372</link>
    <description>&lt;P&gt;If the current format is MMDDYY10 as it appears you may only need to change the FORMAT to MMDDYYN8.&lt;/P&gt;
&lt;P&gt;You could do this as need for display in a procedure or in a data step to permanently modify the variable:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Format DOB mmddyyn8.;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 16 Sep 2016 17:56:35 GMT</pubDate>
    <dc:creator>ballardw</dc:creator>
    <dc:date>2016-09-16T17:56:35Z</dc:date>
    <item>
      <title>converting date of birth to required spec</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/converting-date-of-birth-to-required-spec/m-p/298993#M60371</link>
      <description>&lt;P&gt;The date I have for DOB in a file I imported looks like this:&lt;/P&gt;
&lt;P&gt;12/11/2000 &amp;nbsp;(my proc contents says that the FORMAT and INFORMAT is numeric).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I need to convert DOB values to that 12/11/2000 becomes 12112000.&lt;/P&gt;
&lt;P&gt;When I use the code below and run a PROC FREQ the data displays as numeric values in the output.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;data student2 (rename=(dob2=dob));&lt;BR /&gt;*ASSIGN LENGTH OF REQUIRED VARS*;&lt;BR /&gt;length last_name $35 first_name $20 middle_name $1 ;&lt;BR /&gt; set student;&lt;BR /&gt; *DOB*;&lt;BR /&gt; dob2=COMPRESS(dob,"/");&lt;BR /&gt; drop dob;&lt;/P&gt;
&lt;P&gt;run;&lt;/P&gt;</description>
      <pubDate>Fri, 16 Sep 2016 17:22:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/converting-date-of-birth-to-required-spec/m-p/298993#M60371</guid>
      <dc:creator>GreggB</dc:creator>
      <dc:date>2016-09-16T17:22:41Z</dc:date>
    </item>
    <item>
      <title>Re: converting date of birth to required spec</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/converting-date-of-birth-to-required-spec/m-p/298996#M60372</link>
      <description>&lt;P&gt;If the current format is MMDDYY10 as it appears you may only need to change the FORMAT to MMDDYYN8.&lt;/P&gt;
&lt;P&gt;You could do this as need for display in a procedure or in a data step to permanently modify the variable:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Format DOB mmddyyn8.;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 16 Sep 2016 17:56:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/converting-date-of-birth-to-required-spec/m-p/298996#M60372</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2016-09-16T17:56:35Z</dc:date>
    </item>
  </channel>
</rss>

