<?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: function module for next month in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995581#M707641</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;Use the function module LAST_DAY_OF_MONTHS&lt;/P&gt;&lt;P&gt;then Add 1 to the return parameter.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward if helpful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Harini.S&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 05 Nov 2007 09:32:50 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-11-05T09:32:50Z</dc:date>
    <item>
      <title>function module for next month</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995575#M707635</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;  Can you give the function module name for follwoing requirement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If we give the date then it should return next month first date.&lt;/P&gt;&lt;P&gt;ex    &lt;/P&gt;&lt;P&gt;input                         output&lt;/P&gt;&lt;P&gt;01/01/2008            01/02/2008&lt;/P&gt;&lt;P&gt;05/11/2007            01/12/2007&lt;/P&gt;&lt;P&gt;01/12/2007            01/01/2008&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rewards as per ur input.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Y kiran&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 09:19:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995575#M707635</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-05T09:19:34Z</dc:date>
    </item>
    <item>
      <title>Re: function module for next month</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995576#M707636</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi kiran,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you can use :&lt;/P&gt;&lt;P&gt;RP_CALC_DATE_IN_INTERVAL : Add days / months to a date&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;plz reward if useful..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 09:22:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995576#M707636</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-05T09:22:34Z</dc:date>
    </item>
    <item>
      <title>Re: function module for next month</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995577#M707637</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;First use FM  OIL_MONTH_GET_FIRST_LAST&lt;/P&gt;&lt;P&gt; Import parameters               Value&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; I_DATE                          10/10/2007&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; Export parameters               Value&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; E_DATE                          11/10/2007&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then pass this value to OIL_MONTH_GET_FIRST_LAST&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; Import parameters               Value&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; I_MONTH                         00&lt;/P&gt;&lt;P&gt; I_YEAR&lt;/P&gt;&lt;P&gt; I_DATE                          10/10/2007&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; Export parameters               Value&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; E_FIRST_DAY                     10/01/2007&lt;/P&gt;&lt;P&gt; E_LAST_DAY                      10/31/2007&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Shiva&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 09:25:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995577#M707637</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-05T09:25:57Z</dc:date>
    </item>
    <item>
      <title>Re: function module for next month</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995578#M707638</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi Kiran,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am not sure, if FM exists but you can use the following logic:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  DATA: L_DATE LIKE SY-DATUM.&lt;/P&gt;&lt;P&gt;  DATA: L_YEAR TYPE I.&lt;/P&gt;&lt;P&gt;  DATA: L_MONTH TYPE I.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  MOVE '01' TO L_DATE+6(2).&lt;/P&gt;&lt;P&gt;  MOVE L_DATE(4) TO L_YEAR.&lt;/P&gt;&lt;P&gt;  MOVE L_DATE+4(2) TO L_MONTH.&lt;/P&gt;&lt;P&gt;  L_MONTH = L_MONTH + 1.&lt;/P&gt;&lt;P&gt;  IF L_MONTH GT 12.&lt;/P&gt;&lt;P&gt;    L_YEAR = L_YEAR + 1.&lt;/P&gt;&lt;P&gt;    L_MONTH = 1.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;  MOVE L_YEAR TO L_DATE(4).&lt;/P&gt;&lt;P&gt;  MOVE L_MONTH TO L_DATE+4(2).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;l_date should be your input.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope this helps&lt;/P&gt;&lt;P&gt;ec&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 09:28:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995578#M707638</guid>
      <dc:creator>JozsefSzikszai</dc:creator>
      <dc:date>2007-11-05T09:28:07Z</dc:date>
    </item>
    <item>
      <title>Re: function module for next month</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995579#M707639</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;First Call the FM&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;RP_LAST_DAY_OF_MONTHS  : To Determine last day of month &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then Add 1 to the Date. It will give the First day of Next month.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;reward if Helpful.&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 09:31:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995579#M707639</guid>
      <dc:creator>varma_narayana</dc:creator>
      <dc:date>2007-11-05T09:31:45Z</dc:date>
    </item>
    <item>
      <title>Re: function module for next month</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995580#M707640</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kiran,&lt;/P&gt;&lt;P&gt;Try This FM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'RE_ADD_MONTH_TO_DATE'&lt;/P&gt;&lt;P&gt;  EXPORTING&lt;/P&gt;&lt;P&gt;    months             = 1&lt;/P&gt;&lt;P&gt;    olddate             = ws_startdate (01.02.2007)&lt;/P&gt;&lt;P&gt;  IMPORTING&lt;/P&gt;&lt;P&gt;    NEWDATE       = ws_date. (01.03.2007)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;or use the fm &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'HR_JP_ADD_MONTH_TO_DATE'&lt;/P&gt;&lt;P&gt;      EXPORTING&lt;/P&gt;&lt;P&gt;        iv_monthcount = ws_01&lt;/P&gt;&lt;P&gt;        iv_date       = lws_date (01.02.2007)&lt;/P&gt;&lt;P&gt;      IMPORTING&lt;/P&gt;&lt;P&gt;        ev_date       = lws_date.(01.03.2007&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward If Useful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Chitra&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 09:32:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995580#M707640</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-05T09:32:43Z</dc:date>
    </item>
    <item>
      <title>Re: function module for next month</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995581#M707641</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;Use the function module LAST_DAY_OF_MONTHS&lt;/P&gt;&lt;P&gt;then Add 1 to the return parameter.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward if helpful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Harini.S&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 09:32:50 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995581#M707641</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-05T09:32:50Z</dc:date>
    </item>
    <item>
      <title>Re: function module for next month</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995582#M707642</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Use the FM:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MONTH_PLUS_DETERMINE Add or subtract months from a date. To subtract a month, enter a negative value for the 'months' parameter. &lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example: &lt;/P&gt;&lt;P&gt;data: new_date type d.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'MONTH_PLUS_DETERMINE'&lt;/P&gt;&lt;P&gt;  EXPORTING&lt;/P&gt;&lt;P&gt;    months        = 1      " Negative to subtract from old date, positive to add&lt;/P&gt;&lt;P&gt;    olddate       = sy-datum&lt;/P&gt;&lt;P&gt; IMPORTING&lt;/P&gt;&lt;P&gt;   NEWDATE       = new_date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;write: / new_date + 1.&lt;/P&gt;&lt;P&gt;                  &lt;/P&gt;&lt;P&gt; Hope this helps.&lt;/P&gt;&lt;P&gt;Reward if helpful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Sipra&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 09:38:16 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995582#M707642</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-05T09:38:16Z</dc:date>
    </item>
    <item>
      <title>Re: function module for next month</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995583#M707643</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;use code as below :  &amp;lt;b&amp;gt;test Just copy and paste&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data : IV_DATE TYPE  D,&lt;/P&gt;&lt;P&gt;EV_MONTH_BEGIN_DATE TYPE  D,&lt;/P&gt;&lt;P&gt;EV_MONTH_END_DATE TYPE  D,&lt;/P&gt;&lt;P&gt;next_month type BKPF-BLDAT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;iv_date = '20070101'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'HR_JP_MONTH_BEGIN_END_DATE'&lt;/P&gt;&lt;P&gt;  EXPORTING&lt;/P&gt;&lt;P&gt;    iv_date                   = iv_date&lt;/P&gt;&lt;P&gt; IMPORTING&lt;/P&gt;&lt;P&gt;   EV_MONTH_BEGIN_DATE       = EV_MONTH_BEGIN_DATE&lt;/P&gt;&lt;P&gt;   EV_MONTH_END_DATE         = EV_MONTH_END_DATE&lt;/P&gt;&lt;P&gt;          .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;write : EV_MONTH_BEGIN_DATE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'J_1H_CAL_DATE_IN_INTERVAL'&lt;/P&gt;&lt;P&gt;  EXPORTING&lt;/P&gt;&lt;P&gt;    date            = EV_MONTH_BEGIN_DATE&lt;/P&gt;&lt;P&gt;    days            = 00&lt;/P&gt;&lt;P&gt;    months          = 01&lt;/P&gt;&lt;P&gt;   SIGNUM          = '+'&lt;/P&gt;&lt;P&gt;    years           = 00&lt;/P&gt;&lt;P&gt; IMPORTING&lt;/P&gt;&lt;P&gt;   CALC_DATE       = next_month&lt;/P&gt;&lt;P&gt;          .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;WRITE / next_month.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;sandeep kaushik&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 09:41:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995583#M707643</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-05T09:41:32Z</dc:date>
    </item>
    <item>
      <title>Re: function module for next month</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995584#M707644</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I think there is no Standard Fm ( not Sure ).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;u can ise these two FM to get output&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;OIL_GET_NEXT_MONTH -&lt;/P&gt;&lt;HR originaltext="---" /&gt;&lt;P&gt;&amp;gt; gives Next month and pass this value to this FM&lt;/P&gt;&lt;P&gt;RE_BE_CALC_START_DATE ---&amp;gt; gives  start date of the month.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward if useful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vimal&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Nov 2007 09:43:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-for-next-month/m-p/2995584#M707644</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-11-05T09:43:11Z</dc:date>
    </item>
  </channel>
</rss>

