<?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: Avoid multiple execution of ABAP program in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/avoid-multiple-execution-of-abap-program/m-p/8180022#M1624170</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try using standard SAP locking concept for this purpose, e.g. lock object ES_PROG. Set the lock at the start of the program, if this fails, then the report is still running and you can exit there. Locks are being released implicitely at the end of program execution, and as well when the system is being restarted.&lt;/P&gt;&lt;P&gt;Thomas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 19 Sep 2011 20:11:48 GMT</pubDate>
    <dc:creator>ThomasZloch</dc:creator>
    <dc:date>2011-09-19T20:11:48Z</dc:date>
    <item>
      <title>Avoid multiple execution of ABAP program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/avoid-multiple-execution-of-abap-program/m-p/8180017#M1624165</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've developped a ABAP program which is running in background (per job) every single hour.&lt;/P&gt;&lt;P&gt;I was wondering if there is a way to check whether the program is still active before starting the program the next time.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I actually save the state of the execution in a SAP table. But this solution has one big disadvantage. In case of SAP goes down&lt;/P&gt;&lt;P&gt;for whatever reason (backup, crash,...), the table entry is not resetted and the program doesn't start again, cause table entry indicates that it's still active.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Does someone has an idea on how to check the job queue status within ABAP?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thx in advance&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Sep 2011 09:24:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/avoid-multiple-execution-of-abap-program/m-p/8180017#M1624165</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-09-19T09:24:12Z</dc:date>
    </item>
    <item>
      <title>Re: Avoid multiple execution of ABAP program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/avoid-multiple-execution-of-abap-program/m-p/8180018#M1624166</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi ,&lt;/P&gt;&lt;P&gt;when you create the background job you can put in a condition in the steps.&lt;/P&gt;&lt;P&gt;To execute only after a specified job is executed completely.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Sep 2011 09:35:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/avoid-multiple-execution-of-abap-program/m-p/8180018#M1624166</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-09-19T09:35:08Z</dc:date>
    </item>
    <item>
      <title>Re: Avoid multiple execution of ABAP program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/avoid-multiple-execution-of-abap-program/m-p/8180019#M1624167</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;     Instead of checking job status in Ztable , you can check with FM BP_JOB_READ to know the status.&lt;/P&gt;&lt;P&gt;This will have the status even if the job terminated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Ravi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Sep 2011 10:14:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/avoid-multiple-execution-of-abap-program/m-p/8180019#M1624167</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-09-19T10:14:24Z</dc:date>
    </item>
    <item>
      <title>Re: Avoid multiple execution of ABAP program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/avoid-multiple-execution-of-abap-program/m-p/8180020#M1624168</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;&lt;/P&gt;&lt;P&gt; You can check with  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FUNCTION MODULE  "TH_WPINFO" &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;Deepak.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Sep 2011 10:45:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/avoid-multiple-execution-of-abap-program/m-p/8180020#M1624168</guid>
      <dc:creator>deepak_dhamat</dc:creator>
      <dc:date>2011-09-19T10:45:47Z</dc:date>
    </item>
    <item>
      <title>Re: Avoid multiple execution of ABAP program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/avoid-multiple-execution-of-abap-program/m-p/8180021#M1624169</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can get the background job info in table TBTCO ( Job Status Overview Table ). Check the status of the&lt;/P&gt;&lt;P&gt;earlier job by passing jobname and get its running status.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Pawan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Sep 2011 11:07:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/avoid-multiple-execution-of-abap-program/m-p/8180021#M1624169</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-09-19T11:07:53Z</dc:date>
    </item>
    <item>
      <title>Re: Avoid multiple execution of ABAP program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/avoid-multiple-execution-of-abap-program/m-p/8180022#M1624170</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try using standard SAP locking concept for this purpose, e.g. lock object ES_PROG. Set the lock at the start of the program, if this fails, then the report is still running and you can exit there. Locks are being released implicitely at the end of program execution, and as well when the system is being restarted.&lt;/P&gt;&lt;P&gt;Thomas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Sep 2011 20:11:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/avoid-multiple-execution-of-abap-program/m-p/8180022#M1624170</guid>
      <dc:creator>ThomasZloch</dc:creator>
      <dc:date>2011-09-19T20:11:48Z</dc:date>
    </item>
  </channel>
</rss>

