<?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: How to make a loop to add all years from the date series in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/How-to-make-a-loop-to-add-all-years-from-the-date-series/m-p/630084#M77643</link>
    <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data want;
    set have;
    do year=start_year to end_year by 1;  
        output;
     end;
    drop start_year end_year;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Fri, 06 Mar 2020 14:18:17 GMT</pubDate>
    <dc:creator>PaigeMiller</dc:creator>
    <dc:date>2020-03-06T14:18:17Z</dc:date>
    <item>
      <title>How to make a loop to add all years from the date series</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-make-a-loop-to-add-all-years-from-the-date-series/m-p/630083#M77642</link>
      <description>&lt;P&gt;Imagine I got Data set like:&lt;/P&gt;&lt;P&gt;ID&amp;nbsp; &amp;nbsp; &amp;nbsp; START_YEAR&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;END_YEAR&lt;/P&gt;&lt;P&gt;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 2015&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; 2017&lt;/P&gt;&lt;P&gt;my target is to convert this to:&lt;/P&gt;&lt;P&gt;ID&amp;nbsp; &amp;nbsp; &amp;nbsp;YEAR&lt;/P&gt;&lt;P&gt;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2015&lt;/P&gt;&lt;P&gt;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2016&lt;/P&gt;&lt;P&gt;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2017&lt;/P&gt;&lt;P&gt;Do you have any solution?&lt;/P&gt;</description>
      <pubDate>Fri, 06 Mar 2020 14:14:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-make-a-loop-to-add-all-years-from-the-date-series/m-p/630083#M77642</guid>
      <dc:creator>PatrykSAS</dc:creator>
      <dc:date>2020-03-06T14:14:24Z</dc:date>
    </item>
    <item>
      <title>Re: How to make a loop to add all years from the date series</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-make-a-loop-to-add-all-years-from-the-date-series/m-p/630084#M77643</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data want;
    set have;
    do year=start_year to end_year by 1;  
        output;
     end;
    drop start_year end_year;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 06 Mar 2020 14:18:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-make-a-loop-to-add-all-years-from-the-date-series/m-p/630084#M77643</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2020-03-06T14:18:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to make a loop to add all years from the date series</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-make-a-loop-to-add-all-years-from-the-date-series/m-p/630085#M77644</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/315439"&gt;@PatrykSAS&lt;/a&gt;&amp;nbsp;Welcome to the SAS Community &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;There you go&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data have;
input ID START_YEAR END_YEAR;
datalines;
1 2015 2017
;

data want (keep=id year);
   set have;
   do year = start_year to end_year;
      output;
   end;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 06 Mar 2020 14:18:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-make-a-loop-to-add-all-years-from-the-date-series/m-p/630085#M77644</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2020-03-06T14:18:27Z</dc:date>
    </item>
  </channel>
</rss>

