<?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: creating new date variable from separate month and year in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/creating-new-date-variable-from-separate-month-and-year/m-p/65855#M18779</link>
    <description>Hello BenRB,&lt;BR /&gt;
&lt;BR /&gt;
You could use the following code:&lt;BR /&gt;
[pre]&lt;BR /&gt;
data i;&lt;BR /&gt;
  month=5;&lt;BR /&gt;
  year=2011;&lt;BR /&gt;
  date=MDY(month,01,year);&lt;BR /&gt;
  format date mmyyp8.;&lt;BR /&gt;
run;&lt;BR /&gt;
[/pre]&lt;BR /&gt;
Sincerely,&lt;BR /&gt;
SPR</description>
    <pubDate>Fri, 13 May 2011 17:36:24 GMT</pubDate>
    <dc:creator>SPR</dc:creator>
    <dc:date>2011-05-13T17:36:24Z</dc:date>
    <item>
      <title>creating new date variable from separate month and year</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/creating-new-date-variable-from-separate-month-and-year/m-p/65854#M18778</link>
      <description>I am merging two datasets - one dataset has the date recorded as separate month and year variables. I want to convert these into a single variable for the date in the format mm.yyyy, to match the date variable in the second dataset.&lt;BR /&gt;
Is this possible? Any advice is appreciated</description>
      <pubDate>Fri, 13 May 2011 17:29:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/creating-new-date-variable-from-separate-month-and-year/m-p/65854#M18778</guid>
      <dc:creator>BenRB</dc:creator>
      <dc:date>2011-05-13T17:29:18Z</dc:date>
    </item>
    <item>
      <title>Re: creating new date variable from separate month and year</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/creating-new-date-variable-from-separate-month-and-year/m-p/65855#M18779</link>
      <description>Hello BenRB,&lt;BR /&gt;
&lt;BR /&gt;
You could use the following code:&lt;BR /&gt;
[pre]&lt;BR /&gt;
data i;&lt;BR /&gt;
  month=5;&lt;BR /&gt;
  year=2011;&lt;BR /&gt;
  date=MDY(month,01,year);&lt;BR /&gt;
  format date mmyyp8.;&lt;BR /&gt;
run;&lt;BR /&gt;
[/pre]&lt;BR /&gt;
Sincerely,&lt;BR /&gt;
SPR</description>
      <pubDate>Fri, 13 May 2011 17:36:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/creating-new-date-variable-from-separate-month-and-year/m-p/65855#M18779</guid>
      <dc:creator>SPR</dc:creator>
      <dc:date>2011-05-13T17:36:24Z</dc:date>
    </item>
  </channel>
</rss>

