<?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: error when executing BAPI_GOODSMVT_CREATE in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-executing-bapi-goodsmvt-create/m-p/3864155#M928765</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;   Refer the theard for sample code.&lt;/P&gt;&lt;P&gt;&lt;A href="https://forums.sdn.sap.com/click.jspa?searchID=12059148&amp;amp;messageID=1383395" target="test_blank"&gt;https://forums.sdn.sap.com/click.jspa?searchID=12059148&amp;amp;messageID=1383395&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Kiran Sure&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 22 May 2008 04:43:23 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-05-22T04:43:23Z</dc:date>
    <item>
      <title>error when executing BAPI_GOODSMVT_CREATE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-executing-bapi-goodsmvt-create/m-p/3864153#M928763</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 i am running a BAPI(BAPI_GOODSMVT_CREATE) it is throwing an error.&lt;/P&gt;&lt;P&gt;error:The FM MB_CREATE_GOODS_MOVEMENT is called up for second time.After it was called up for the first time Commit work was not done.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But i called BAPI_Transaction commit after BAPI_GOODSMVT_CREATE but even then it was throwing error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Helpful answer will be rewarded.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 22 May 2008 04:35:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-executing-bapi-goodsmvt-create/m-p/3864153#M928763</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-22T04:35:44Z</dc:date>
    </item>
    <item>
      <title>Re: error when executing BAPI_GOODSMVT_CREATE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-executing-bapi-goodsmvt-create/m-p/3864154#M928764</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;May be commit work is not being called properly try&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    call function 'BAPI_GOODSMVT_CREATE'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;      call function 'BAPI_TRANSACTION_COMMIT'&lt;/P&gt;&lt;P&gt;        EXPORTING&lt;/P&gt;&lt;P&gt;          wait   = 'X'&lt;/P&gt;&lt;P&gt;        IMPORTING&lt;/P&gt;&lt;P&gt;          return = i_return.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check i_return to find out what is the exact reason.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    then call for 2nd time&lt;/P&gt;&lt;P&gt;   call function 'BAPI_GOODSMVT_CREATE'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;anya&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 22 May 2008 04:41:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-executing-bapi-goodsmvt-create/m-p/3864154#M928764</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-22T04:41:18Z</dc:date>
    </item>
    <item>
      <title>Re: error when executing BAPI_GOODSMVT_CREATE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-executing-bapi-goodsmvt-create/m-p/3864155#M928765</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;   Refer the theard for sample code.&lt;/P&gt;&lt;P&gt;&lt;A href="https://forums.sdn.sap.com/click.jspa?searchID=12059148&amp;amp;messageID=1383395" target="test_blank"&gt;https://forums.sdn.sap.com/click.jspa?searchID=12059148&amp;amp;messageID=1383395&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Kiran Sure&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 22 May 2008 04:43:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-executing-bapi-goodsmvt-create/m-p/3864155#M928765</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-22T04:43:23Z</dc:date>
    </item>
    <item>
      <title>Re: error when executing BAPI_GOODSMVT_CREATE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-executing-bapi-goodsmvt-create/m-p/3864156#M928766</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Prince,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please try this way&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;call function 'BAPI_GOODSMVT_CREATE'
  exporting
    goodsmvt_header             = gmhead
    goodsmvt_code               = gmcode
*   TESTRUN                     = ' '
* IMPORTING
    goodsmvt_headret            = mthead
*   MATERIALDOCUMENT            =
*   MATDOCUMENTYEAR             =
  tables
    goodsmvt_item               = itab
*   GOODSMVT_SERIALNUMBER       =
    return                      = errmsg
          .
clear errflag.
loop at errmsg.
  if errmsg-type eq 'E'.
    write:/'Error in function', errmsg-message.
    errflag = 'X'.
  else.
    write:/ errmsg-message.
  endif.
endloop.

if errflag is initial.
  commit work and wait.
  if sy-subrc ne 0.
    write:/ 'Error in updating'.
    exit.
  else.
    write:/ mthead-mat_doc, mthead-doc_year.
    perform upd_sta.
  endif.
endif.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;raam&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 22 May 2008 04:43:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/error-when-executing-bapi-goodsmvt-create/m-p/3864156#M928766</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-05-22T04:43:53Z</dc:date>
    </item>
  </channel>
</rss>

