<?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: calling multiple times BAPI_GOODSMVT_CREATE getting error in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481491#M225197</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You get the error because locks in the update work process are not released yet when you call the bapi second time.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can try adding SET UPDATE TASK LOCAL before calling the bapi.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Sridhar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 11 Aug 2006 18:35:19 GMT</pubDate>
    <dc:creator>sridhar_k1</dc:creator>
    <dc:date>2006-08-11T18:35:19Z</dc:date>
    <item>
      <title>calling multiple times BAPI_GOODSMVT_CREATE getting error</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481485#M225191</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am calling multiple times BAPI_GOODSMVT_CREATE for same Purchase order to post goods receipt.&lt;/P&gt;&lt;P&gt;first goods receipt created successfully but second one has given the error the Purchase order is lockecd by USER 'XXXX' .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i am calling 'BAPI_TRANSACTION_COMMIT after each BAPI BAPI_GOODSMVT_CREATE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i tried with passing parameter WAIT = 'X' in 'BAPI_TRANSACTION_COMMIT. then also getting same error message.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;please any one tell me the solution&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Aug 2006 15:11:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481485#M225191</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-11T15:11:39Z</dc:date>
    </item>
    <item>
      <title>Re: calling multiple times BAPI_GOODSMVT_CREATE getting error</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481486#M225192</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Why are you calling it multiple times for the same purchase order?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Aug 2006 15:13:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481486#M225192</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2006-08-11T15:13:39Z</dc:date>
    </item>
    <item>
      <title>Re: calling multiple times BAPI_GOODSMVT_CREATE getting error</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481487#M225193</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try DEQUEUEing after the commit.  Here is a sample coding.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

* Call goods movement BAPI
call function 'BAPI_GOODSMVT_CREATE'
     exporting
          goodsmvt_header  = gm_header
          goodsmvt_code    = gm_code
     importing
          goodsmvt_headret = gm_headret
          materialdocument = gm_retmtd
     tables
          goodsmvt_item    = gm_item
          return           = gm_return.

if not gm_retmtd is initial.
&amp;lt;b&amp;gt;  commit work and wait.
  call function 'DEQUEUE_ALL'.&amp;lt;/b&amp;gt;
  write:/ gm_retmtd.
else.
  commit work and wait.
  call function 'DEQUEUE_ALL'.
endif.


&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Aug 2006 15:15:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481487#M225193</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2006-08-11T15:15:38Z</dc:date>
    </item>
    <item>
      <title>Re: calling multiple times BAPI_GOODSMVT_CREATE getting error</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481488#M225194</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Or you can just keep adding the receipts to the gm_item tab and process the BAPI once for each po number. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That works to.&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;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Aug 2006 15:18:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481488#M225194</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2006-08-11T15:18:07Z</dc:date>
    </item>
    <item>
      <title>Re: calling multiple times BAPI_GOODSMVT_CREATE getting error</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481489#M225195</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;thanks for your reply&lt;/P&gt;&lt;P&gt;we have requirement partial goods receipts for purchase orders diffrent times.&lt;/P&gt;&lt;P&gt;so i need to call each time BAPI_GOODS_MVT_CREATE for each parial goods receipt.&lt;/P&gt;&lt;P&gt;i will try with call function 'DEQUEUE_ALL'.&lt;/P&gt;&lt;P&gt;please can you expalain what is the use of WAIT parameter in 'BAPI_TRANSACATION_COMMIT'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Aug 2006 15:45:15 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481489#M225195</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-11T15:45:15Z</dc:date>
    </item>
    <item>
      <title>Re: calling multiple times BAPI_GOODSMVT_CREATE getting error</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481490#M225196</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use wait for 5 seconds.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Aug 2006 16:25:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481490#M225196</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-11T16:25:33Z</dc:date>
    </item>
    <item>
      <title>Re: calling multiple times BAPI_GOODSMVT_CREATE getting error</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481491#M225197</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You get the error because locks in the update work process are not released yet when you call the bapi second time.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can try adding SET UPDATE TASK LOCAL before calling the bapi.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Sridhar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Aug 2006 18:35:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/calling-multiple-times-bapi-goodsmvt-create-getting-error/m-p/1481491#M225197</guid>
      <dc:creator>sridhar_k1</dc:creator>
      <dc:date>2006-08-11T18:35:19Z</dc:date>
    </item>
  </channel>
</rss>

