<?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 Calling a background Job from RFC enabled Function Module in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-a-background-job-from-rfc-enabled-function-module/m-p/5484965#M1255477</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Experts ,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a requirement to call a background Job from RFC Enabled Function Module . As soon as the background job is called , RFC enabled Function Module should  exit or complete.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please advise anyway of achieveing this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Shital.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 10 Apr 2009 12:46:25 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-04-10T12:46:25Z</dc:date>
    <item>
      <title>Calling a background Job from RFC enabled Function Module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-a-background-job-from-rfc-enabled-function-module/m-p/5484965#M1255477</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Experts ,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a requirement to call a background Job from RFC Enabled Function Module . As soon as the background job is called , RFC enabled Function Module should  exit or complete.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please advise anyway of achieveing this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Shital.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Apr 2009 12:46:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-a-background-job-from-rfc-enabled-function-module/m-p/5484965#M1255477</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-10T12:46:25Z</dc:date>
    </item>
    <item>
      <title>Re: Calling a background Job from RFC enabled Function Module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-a-background-job-from-rfc-enabled-function-module/m-p/5484966#M1255478</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just use a [JOB_OPEN, SUBMIT and JOB_CLOSE|http://help.sap.com/erp2005_ehp_04/helpdata/EN/fa/096ee5543b11d1898e0000e8322d00/frameset.htm] in your RFC enabled FM. (Don't forget to provide print parameters if needed if the call comes actually from an external system)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You may also [call your RFC FM in an asynchronous way|http://help.sap.com/erp2005_ehp_04/helpdata/EN/22/042592488911d189490000e829fbbd/frameset.htm] (STARTING NEW TASK) &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Apr 2009 13:20:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-a-background-job-from-rfc-enabled-function-module/m-p/5484966#M1255478</guid>
      <dc:creator>RaymondGiuseppi</dc:creator>
      <dc:date>2009-04-10T13:20:30Z</dc:date>
    </item>
    <item>
      <title>Re: Calling a background Job from RFC enabled Function Module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-a-background-job-from-rfc-enabled-function-module/m-p/5484967#M1255479</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;when you call a job in RFC, the background job starts and the function module is not in command ..&lt;/P&gt;&lt;P&gt;so you need not worry.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;CALL FUNCTION 'JOB_OPEN' 
EXPORTING 
JOBNAME = JOBNAME 
IMPORTING 
JOBCOUNT = JOBNUMBER 
EXCEPTIONS 
CANT_CREATE_JOB = 01 
INVALID_JOB_DATA = 02 
JOBNAME_MISSING = 03 
OTHERS = 99. 

IF SY-SUBRC &amp;gt; 0. 
&amp;lt;Error processing&amp;gt; 
ENDIF.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;JOB_SUBMIT.&lt;/CODE&gt;&lt;/PRE&gt;&lt;PRE&gt;&lt;CODE&gt;JOB_CLOSE.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;To create variants you can use&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;RS_VARIANT_LIST&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Lalit Mohan Gupta.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Apr 2009 13:30:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-a-background-job-from-rfc-enabled-function-module/m-p/5484967#M1255479</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-10T13:30:41Z</dc:date>
    </item>
    <item>
      <title>Re: Calling a background Job from RFC enabled Function Module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-a-background-job-from-rfc-enabled-function-module/m-p/5484968#M1255480</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;Thanks for your reply.It is helpfull.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could you please comment if Function Module BP_EVENT_RAISE can be helpfull for this requirement?&lt;/P&gt;&lt;P&gt;If yes , please elaborate on this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Shital.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 Apr 2009 07:02:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-a-background-job-from-rfc-enabled-function-module/m-p/5484968#M1255480</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-13T07:02:39Z</dc:date>
    </item>
    <item>
      <title>Re: Calling a background Job from RFC enabled Function Module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-a-background-job-from-rfc-enabled-function-module/m-p/5484969#M1255481</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;Thanks for your reply.It is helpfull.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could you please comment if Function Module BP_EVENT_RAISE can be helpfull for this requirement?&lt;/P&gt;&lt;P&gt;If yes , please elaborate on this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Shital.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 Apr 2009 07:02:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-a-background-job-from-rfc-enabled-function-module/m-p/5484969#M1255481</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-13T07:02:54Z</dc:date>
    </item>
    <item>
      <title>Re: Calling a background Job from RFC enabled Function Module</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-a-background-job-from-rfc-enabled-function-module/m-p/5484970#M1255482</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Shital,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yes, the FM BP_EVENT_RAISE will be helpful in this case:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is an example for the FM , Let me know if you have any questions!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Report processing before triggering event...&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Trigger event to start background jobs waiting for the event. &lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: EVENTID LIKE TBTCJOB-EVENTID. &lt;/P&gt;&lt;P&gt;DATA: EVENTPARM LIKE TBTCJOB-EVENTPARM. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EVENTID = 'SP_TEST_EVENT'. " Event name must be defined &lt;/P&gt;&lt;P&gt;" with transaction SM62. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EVENTPARM = 'EVENT1'. " Optional: a job can be &lt;/P&gt;&lt;P&gt;" scheduled to wait for an &lt;/P&gt;&lt;P&gt;" EVENTID or combination of &lt;/P&gt;&lt;P&gt;" EVENTID and EVENTPARM. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'BP_EVENT_RAISE' " Event is triggered. Jobs &lt;/P&gt;&lt;P&gt;EXPORTING " waiting for event will be &lt;/P&gt;&lt;P&gt;EVENTID = EVENTID " started.&lt;/P&gt;&lt;P&gt;EVENTPARM = EVENTPARM &lt;/P&gt;&lt;P&gt;TARGET_INSTANCE = u2018 u2018 " Instance at which an event &lt;/P&gt;&lt;P&gt;" should be processed. Can &lt;/P&gt;&lt;P&gt;" generally be omitted. &lt;/P&gt;&lt;P&gt;EXCEPTIONS OTHERS = 1. " Exceptions include event not &lt;/P&gt;&lt;P&gt;" defined, no EVENTID &lt;/P&gt;&lt;P&gt;" exported, etc.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jul 2009 18:32:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-a-background-job-from-rfc-enabled-function-module/m-p/5484970#M1255482</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-07-06T18:32:32Z</dc:date>
    </item>
  </channel>
</rss>

