Skip to Content
0

Require Exit/Enhancement/Badi after commit work for MIGO

Jan 16, 2017 at 10:04 AM

304

avatar image

Hi All,

I am trying to post MIGO 109 document, my requirement is to send the Material document details to another system via RFC, so i need a Badi/Exit/Enhacement/implicit/explicit which should trigger after material document is saved in database, i have already used

MB_DOCUMENT_BADI of methods MB_DOCUMENT_UPDATE but it is not triggering.

tried almost all badis like MB_MIGO_BADI, also found customer Fn EXIT_SAPLCUD0_003, which is also not triggering.

I request you kindly provide any other Alternative solution,after commit work.

Thanks & Regards,

Ramu

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Raymond Giuseppi
Jan 16, 2017 at 10:09 AM
1

What did you actually try in MB_MIGO_BADI method POST_DOCUMENT?

The POST_DOCUMENT method is to be used to synchronize the data from the external application with the completed material document, directly before posting (using MSEG-LINE_ID), because at this time, the final MSEG lines are known. The external application can renumber its own data if necessary (if it wants to use the MSEG-ZEILE field instead of MSEG-LINE_ID in its own database table).

Regards,
Raymond

Show 5 Share
10 |10000 characters needed characters left characters exceeded

Hi Raymond,

Thanks for reply...here my requirement is to send the material document to other system , only when material document is committed in our standard database tables(MKPF, MSEG) , so i am looking for any exit/spots/badis in which i will write a RFC which send the data to other system. Post Document is triggering before commit work, Please let me know if its clear..:)

Thanks..

Regards,

Ramu

0

Look at the sample implementation of the BAPI, it trigger an update task FM. So if you create a V2 update FM or a RFC enabled FM, you can execute those IN UPDATE or BACKGROUND TASK so the data will already been updated in database.

But are you sure you need to do that, as the POST_DOCUMENT has already most if not all the data which will be written to database, if an error is triggered in update task preventinf data to be inserted, then your FM won't be executed.

Regards,
Raymond

1
Raymond Giuseppi

hi raymond,

Thanks for reply i have followed different approach, as mentioned below

I have a requirement to send GRN posting data after databse commit in ecc, to non ecc system, for which i have written a code in Badi MB_document_badi of method MB_DOCUMENT_UPDATE by calling event FM: BP_EVENT_RAISE passing event which was created in SM62 and this FM calls the background job which holds our RFC with destination... So here the problem is some time's RFC is success and some times it fails , i am getting sy-subrc = 1 as system failure. Attached the Short dump as well. at PI side they were not able to see any messages from ECC.

Kindly help me to fix the issue .

Thanks in advance.

short-dump.pngshort-dump1.png

short-dump.png (62.5 kB)
short-dump1.png (30.6 kB)
0

The message 'Bean not found on host' suggests much more a configuration problem of the PI server than an Abap problem (Program ID registration, Server or host issues, SSO configuration issues, extra listeners?)

0
Raymond Giuseppi

Hi Raymond,

Thanks for Reply, PI and Basis team is also investigating on this issue, but they were unable to find the solution, RFC is success sometimes and fails sometimes randomly.

Any help on this..?

Thanks for support.

Regards,

Ramu

0