0
votes

TL;DR: If you use BAPI_GOODSMVT_CREATE to create multiple co-dependent movements and one of them is a transfer posting, then you need to use a wrapper - per SAP note 369518. If there's no transfer posting somewhere, a COMMIT is enough

Has anyone looked into the specifics of Note 369518?

It describes a requirement to start a new roll area before calling BAPI_GOODSMVT_CREATE for a goods receipt that depends on a previous goods movement (posted also by the BAPI within the same LUW).

What is unclear to me: Does it apply to goods receipts in general? Or somehow only to goods receipts that involve an "implicit" (sic) GI for stock in transfer?

I am looking for a technical walkthrough of the section "Reason and Prerequisites".

I need to decide if for a sequence of movements 262,102,101,261 on the same batch, the BAPI should be called in a new roll area each time. For this, the user will need to be asked to close a window if they have the maximum internal sessions already open. (Edit: The part in italics may not apply as I believe that DESTINATION 'NONE' will start a new user session)

1
You must not copy external text, it's copyright infringement concerning SAP. This text is also not public and can only be accessed by people who purchase SAP software. Please remove it. For more information, see help center. - Sandra Rossi
I don't know if you ask out of curiosity, of If you have an actual issue. In the latter case, please explain it in details. - Sandra Rossi
A note applies to what is described in its chapter "symptom", nothing more. If any doubt, please contact SAP support. - Sandra Rossi
I am also curious to understand what they mean there. I have searched but couldn't find more info. I am hoping someone here has a better understanding of the technical aspects. - Pilot
The term "roll area" used in the note is to be understood like the "memory of an internal session". If you call several BAPI via RFC without closing the connection, the first call may store global data that the second call can see and use. I think the "RFC session" chapter of the ABAP documentation describes it well. - Sandra Rossi

1 Answers

0
votes

Best I can tell, the answer hinges on the note's "machine translation" into English: Google offers the alternative phrasing "only with a real outgoing goods, inventory is read from the database", which clears it up a bit:

The BAPI looks into the buffer always, regardless of which movement type it is tasked to create. The issue is that a transfer posting (A08 in MIGO) does not update the buffer. While a "real outgoing" goods issue (A07 in MIGO) does, allowing the subsequent goods receipt to correctly detect the stock.

So only if a prerequisite movement is a transfer posting, is it necessary to start the dependent call in a new roll area.