<?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 Calculate the year which is 20 years from run date. in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646635#M22082</link>
    <description>Hi thanks,&lt;BR /&gt;I have replied to another question.</description>
    <pubDate>Mon, 11 May 2020 11:18:37 GMT</pubDate>
    <dc:creator>annypanny</dc:creator>
    <dc:date>2020-05-11T11:18:37Z</dc:date>
    <item>
      <title>How to Calculate the year which is 20 years from run date.</title>
      <link>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646591#M22077</link>
      <description>&lt;P&gt;How to Calculate the year which is 20 years from run date. E.g if today’s date is 11MAY2020, then this step will give year 2040.&lt;/P&gt;
&lt;P&gt;I have used the below code but didn't find the solution.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;data want;&lt;BR /&gt;set have;&lt;BR /&gt;do n=1 to 20 by +1;&lt;BR /&gt;date=intnx('year', &amp;amp;rundate, +n);&lt;BR /&gt;format date ddmmyyn8.;&lt;BR /&gt;output;&lt;BR /&gt;end;&lt;BR /&gt;run;&lt;/P&gt;</description>
      <pubDate>Mon, 11 May 2020 09:24:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646591#M22077</guid>
      <dc:creator>annypanny</dc:creator>
      <dc:date>2020-05-11T09:24:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to Calculate the year which is 20 years from run date.</title>
      <link>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646596#M22078</link>
      <description>&lt;P&gt;no need of do loop, please try the below code&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data want;
date=intnx('year', today(), +20,'SAME');
format date ddmmyyn8.;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 11 May 2020 09:39:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646596#M22078</guid>
      <dc:creator>Jagadishkatam</dc:creator>
      <dc:date>2020-05-11T09:39:07Z</dc:date>
    </item>
    <item>
      <title>Re: How to Calculate the year which is 20 years from run date.</title>
      <link>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646597#M22079</link>
      <description>&lt;P&gt;HI&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/316738"&gt;@annypanny&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV&gt;You can retrieve the year which is 20 years&amp;nbsp;from run date by using the INTNX function.&lt;/DIV&gt;
&lt;DIV&gt;The modifier "S" tells SAS to pick the same date (-&amp;gt; so 11MAY2040).&lt;/DIV&gt;
&lt;DIV&gt;For your other questions, could you please explain where do we find the collection name? For example, is&amp;nbsp;Flexi 2040-42 (BLK) the name of the production dataset?&lt;/DIV&gt;
&lt;DIV&gt;Best,&lt;/DIV&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data have;
	format today_date date9.;
	today_date = today();
	year20 = year(intnx('year',today_date,20,"s"));
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 11 May 2020 09:44:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646597#M22079</guid>
      <dc:creator>ed_sas_member</dc:creator>
      <dc:date>2020-05-11T09:44:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to Calculate the year which is 20 years from run date.</title>
      <link>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646628#M22080</link>
      <description>&lt;P&gt;Another possibility&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;year_in_future = year(today())+20;&lt;/P&gt;</description>
      <pubDate>Mon, 11 May 2020 10:58:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646628#M22080</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2020-05-11T10:58:58Z</dc:date>
    </item>
    <item>
      <title>Re: How to Calculate the year which is 20 years from run date.</title>
      <link>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646634#M22081</link>
      <description>thanks, it is solved. Can you help me in another question linked with this question.&lt;BR /&gt;&lt;A href="https://communities.sas.com/t5/SAS-Programming/How-to-Calculate-this-steps/td-p/646588" target="_blank"&gt;https://communities.sas.com/t5/SAS-Programming/How-to-Calculate-this-steps/td-p/646588&lt;/A&gt;</description>
      <pubDate>Mon, 11 May 2020 11:18:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646634#M22081</guid>
      <dc:creator>annypanny</dc:creator>
      <dc:date>2020-05-11T11:18:03Z</dc:date>
    </item>
    <item>
      <title>Re: How to Calculate the year which is 20 years from run date.</title>
      <link>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646635#M22082</link>
      <description>Hi thanks,&lt;BR /&gt;I have replied to another question.</description>
      <pubDate>Mon, 11 May 2020 11:18:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646635#M22082</guid>
      <dc:creator>annypanny</dc:creator>
      <dc:date>2020-05-11T11:18:37Z</dc:date>
    </item>
    <item>
      <title>Re: How to Calculate the year which is 20 years from run date.</title>
      <link>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646637#M22083</link>
      <description>Hi thanks, please help me in another question linked with this&lt;BR /&gt;&lt;A href="https://communities.sas.com/t5/SAS-Programming/How-to-Calculate-this-steps/td-p/646588" target="_blank"&gt;https://communities.sas.com/t5/SAS-Programming/How-to-Calculate-this-steps/td-p/646588&lt;/A&gt;</description>
      <pubDate>Mon, 11 May 2020 11:19:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/How-to-Calculate-the-year-which-is-20-years-from-run-date/m-p/646637#M22083</guid>
      <dc:creator>annypanny</dc:creator>
      <dc:date>2020-05-11T11:19:19Z</dc:date>
    </item>
  </channel>
</rss>

