<?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: Running Function Module in Background with Update Task is not working in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/running-function-module-in-background-with-update-task-is-not-working/m-p/8578381#M1660569</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try using the Function Modules JOB_OPEN_ADK, JOB_SUBMIT_ADK &amp;amp; JOB_CLOSE_ADK.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 16 Feb 2012 07:56:05 GMT</pubDate>
    <dc:creator>mahalingam_sivaprakash</dc:creator>
    <dc:date>2012-02-16T07:56:05Z</dc:date>
    <item>
      <title>Running Function Module in Background with Update Task is not working</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/running-function-module-in-background-with-update-task-is-not-working/m-p/8578380#M1660568</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Friends,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a "Z" Report Program where I am running this Report in Background using JOB_OPEN, JOB_SUBMIT, JOB_CLOSE. I am calling this in BADI. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In this Report I am calling another Function Module PRICES_POST which is a standard Function Module and in this FM there is another FM 'CKML_UPDATE_MATERIAL_PRICE IN UPDATE TASK'. Now when I am running the BADI these values are not being updated. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Friends I would like to know whether can we run Function Modules which are  included with UPDATE TASK as Background Job program?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kindly help me in providing your valuable suggestions in proceeding further.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks and Regards&lt;/P&gt;&lt;P&gt;Pradeep Goli&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Feb 2012 07:01:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/running-function-module-in-background-with-update-task-is-not-working/m-p/8578380#M1660568</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-02-16T07:01:17Z</dc:date>
    </item>
    <item>
      <title>Re: Running Function Module in Background with Update Task is not working</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/running-function-module-in-background-with-update-task-is-not-working/m-p/8578381#M1660569</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try using the Function Modules JOB_OPEN_ADK, JOB_SUBMIT_ADK &amp;amp; JOB_CLOSE_ADK.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Feb 2012 07:56:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/running-function-module-in-background-with-update-task-is-not-working/m-p/8578381#M1660569</guid>
      <dc:creator>mahalingam_sivaprakash</dc:creator>
      <dc:date>2012-02-16T07:56:05Z</dc:date>
    </item>
    <item>
      <title>Re: Running Function Module in Background with Update Task is not working</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/running-function-module-in-background-with-update-task-is-not-working/m-p/8578382#M1660570</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Usually the sequence of CALLs in your report should look like&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;  CALL FUNCTION 'CM_F_INITIALIZE'
    EXPORTING
      msg_on_screen = c_x.
  CALL FUNCTION 'CKMS_BUFFER_REFRESH_COMPLETE'.
  CALL FUNCTION 'PRICES_CHANGE'
    EXPORTING
      actual_bdatj = f_matpr-pp-bdatj
      actual_poper = f_matpr-pp-poper
      bukrs        = p_bukrs
      budat        = p_date
      xblnr        = p_xblnr
    TABLES
      t_matpr      = t_matpr.
  READ TABLE t_matpr WITH KEY pp-xerror = ' '
                            TRANSPORTING NO FIELDS.
  IF sy-subrc &amp;lt;&amp;gt; 0.
    MESSAGE i046(ckprch).
  ELSE.
    CALL FUNCTION 'PRICES_POST'
      EXPORTING
        i_bktxt    = p_bktxt
        bukrs      = p_bukrs
        lis_update = 'X'
      TABLES
        t_matpr    = t_matpr.
  ENDIF.
  COMMIT WORK.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;If you forget the COMMIT-WORK each and every FM called in UPDATE TASK will not be triggered.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Raymond&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Feb 2012 08:22:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/running-function-module-in-background-with-update-task-is-not-working/m-p/8578382#M1660570</guid>
      <dc:creator>RaymondGiuseppi</dc:creator>
      <dc:date>2012-02-16T08:22:58Z</dc:date>
    </item>
  </channel>
</rss>

