cancel
Showing results for 
Search instead for 
Did you mean: 

BADI after post good issue complete

nicholas_archer3
Explorer
0 Kudos

Hello All,

Is there a BAdI that is called after an outbound delivery post goods issue is completed. I need to update a custom table with consignment stock after the goods movement is completed.

The consignment tables are not updated when method PUBLISH_AFTER_SAVE from definition DELIVERY_PUBLISH is called.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Nicholas,

there is such a thing as a standard consignment stock, so I hope your functional consultant has analysed it.

When I need to update information based on the success of a transaction I develop a customized info structure, in this case it would update my consignment stock table after goods issue creation. If outbound delivery and goods movement haven't all required information to update stock I would also add that fields to LIPS or MSEG table as an append.

Anyway, it is probably simple for you to use badi LE_SHP_GOODSMOVEMENT and place your update to consignment stock table there.

There might be also in there an implementation for catch weight functionality (/CWM/LE_SHP_GOODSMVT) that records a second unit of measure for movements, it might interest you.

Regards,

Edgar

nicholas_archer3
Explorer
0 Kudos

Edgar,


this process needs to occur automatically in the background as standard outbound delivery transactions (vl01n and vl02n) are manually executed. we are not running any custom programs to create the outbound deliveries or post goods issue. What we need is the consignee stock quantities (from table MSKU) after select goods movements is complete. When we extract the available consignment stock quantities using the BAdIs I mentioned as well as the ones you suggested the quantities available prior to the goods movement completion are returned.

Calculating the stock quantities base on current consignment stock and expected results of an outbound delivery goods issue is not an option.

I'm not familiar with info structures.

Former Member
0 Kudos

Hi,

It still isn't clear for me what you're trying to achieve although you've added important info.

Info structures are great but not simple to explain here.

No badi will run before the select to database considers the update info, however you can use them to start a background task or an update task. Inside that function you can read and write to the custom table.

nicholas_archer3
Explorer
0 Kudos

My problem with a background task is determining when the outbound delivery actions (create, change, delete) have finished. Short of putting in a 5 minute delay and hoping for the best.

Are you aware of any functions that can determine when a transaction has ended?

Former Member
0 Kudos

That's why info structures are so great, they act at update event, after transaction commit, so we're sure the document was created with success.

If you have no internal knowledge of info structures one thing you can explore are other events that occur in update modules, like some printing or EDI message associated to the document, and place the code there.

Also, instead of waiting an undefined number of minutes you could check every second or two if the record already exists in LIKP or VBUK.

You can check info structures in SPRO->Logistics - General->Logistics Information System (LIS)->Logistics Data Warehouse

and

http://help.sap.com/erp2005_ehp_07/helpdata/en/c1/3756d5449a11d188fe0000e8322f96/content.htm?framese...

regards,

Edgar

Answers (0)