<?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 Date Calculations in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838673#M1784923</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am working on a new function module where on the selection screen i have the period type ( allowed values are 'D','W','M' for day,week and month).&lt;/P&gt;&lt;P&gt;And have one more input for date_period(it will allow integer upto 999).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My requirement is to calculate a date based on the period_type and date_period.&lt;/P&gt;&lt;P&gt;For example, if the period_type is 'M' (monthly) and date_period is 10, then the date should be current date + 10 months.&lt;/P&gt;&lt;P&gt;if the period_type is 'W' (weekly) and date_period is 10, then the date should be current date + 10 weeks.&lt;/P&gt;&lt;P&gt;And the same with 'D'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please note that i am working in APO environment. There is a FM module in ECC 'RP_CALC_DATE_IN_INTERVAL' which mostly matches my requirement but its not available in APO.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help would be appriciated.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 18 Nov 2013 21:12:24 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2013-11-18T21:12:24Z</dc:date>
    <item>
      <title>Date Calculations</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838673#M1784923</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am working on a new function module where on the selection screen i have the period type ( allowed values are 'D','W','M' for day,week and month).&lt;/P&gt;&lt;P&gt;And have one more input for date_period(it will allow integer upto 999).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My requirement is to calculate a date based on the period_type and date_period.&lt;/P&gt;&lt;P&gt;For example, if the period_type is 'M' (monthly) and date_period is 10, then the date should be current date + 10 months.&lt;/P&gt;&lt;P&gt;if the period_type is 'W' (weekly) and date_period is 10, then the date should be current date + 10 weeks.&lt;/P&gt;&lt;P&gt;And the same with 'D'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please note that i am working in APO environment. There is a FM module in ECC 'RP_CALC_DATE_IN_INTERVAL' which mostly matches my requirement but its not available in APO.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help would be appriciated.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 Nov 2013 21:12:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838673#M1784923</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2013-11-18T21:12:24Z</dc:date>
    </item>
    <item>
      <title>Re: Date Calculations</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838674#M1784924</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you have Class CL_RECA_DATE available in your APO system, you could work with its static methods especially ADD_TO_DATE looks promising in regards to your requirement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Sougata.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 Nov 2013 22:20:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838674#M1784924</guid>
      <dc:creator>Sougata</dc:creator>
      <dc:date>2013-11-18T22:20:57Z</dc:date>
    </item>
    <item>
      <title>Re: Date Calculations</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838675#M1784925</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Unfortunatley, i do not see that class available in our APO system.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 Nov 2013 14:32:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838675#M1784925</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2013-11-19T14:32:50Z</dc:date>
    </item>
    <item>
      <title>Re: Date Calculations</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838676#M1784926</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For adding months, you can try with the FM 'MONTH_PLUS_DETERMINE'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For weeks I don't know any standard FM. Think that each 7 or 8 years there is a year of 53 weeks. You can create your own FM, if for instance you want to add 10 weeks, obtain days (ie: 10 * 7 = 70 days), add these days to the original date and with the FM 'DATE_GET_WEEK' get the weeks for the first day and the calculated day.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope this helps you&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Eduardo&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 Nov 2013 14:46:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838676#M1784926</guid>
      <dc:creator>eduardo_hinojosa</dc:creator>
      <dc:date>2013-11-19T14:46:22Z</dc:date>
    </item>
    <item>
      <title>Re: Date Calculations</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838677#M1784927</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;'MONTH_PLUS_DETERMINE' looks like an ECC Function module. &lt;/P&gt;&lt;P&gt;My requirment is in APO.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 Nov 2013 14:49:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838677#M1784927</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2013-11-19T14:49:19Z</dc:date>
    </item>
    <item>
      <title>Re: Date Calculations</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838678#M1784928</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Found the FM - SEPA_MANDATE_ADD_MONTH_TO_DATE which works for month.&lt;/P&gt;&lt;P&gt;But still need a solution for weeks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 Nov 2013 16:00:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838678#M1784928</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2013-11-19T16:00:34Z</dc:date>
    </item>
    <item>
      <title>Re: Date Calculations</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838679#M1784929</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can you not code your own logic for weeks?&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;End date = Start date + (7 * number of weeks).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Nick&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 19 Nov 2013 16:08:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/date-calculations/m-p/9838679#M1784929</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2013-11-19T16:08:34Z</dc:date>
    </item>
  </channel>
</rss>

