Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

MIGO BAdi or User-Exit after Database Commit

Former Member
0 Likes
2,009

Hi all,

I'm looking for a BAdI or user-exit after database commit for MIGO posting. I want to create a MM document after MIGO posting.

I already tried MB_DOCUMENT_BADI / MB_DOCUMENT_UPDATE but doesnt seem to be triggering. I have put a piece of code but and doing a Update debugging but it doesnt stop there. How can i do that?

Best regards,

Munur

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,321

Hi Nagaraj,

I tried to debug. İt was not stopet to enhancement. Are there any suggestions?

Munur

7 REPLIES 7
Read only

former_member404244
Active Contributor
0 Likes
1,321

Hi,

Check these enhancements MB_CF001 and MBCF0005.

Regards,

Nagaraj

Read only

Former Member
0 Likes
1,322

Hi Nagaraj,

I tried to debug. İt was not stopet to enhancement. Are there any suggestions?

Munur

Read only

0 Likes
1,321

Hi,

While doing MIGO actually "MB_DOCUMENT_BADI" and use method MB_DOCUMENT_BEFORE_UPDATE should work.. also you can check MB_MIGO_BADI.

The other work around is once the migo postings are done for a perticular day , you can write a custom program to read the material documents and then post it as per your requirement..This should be a scheduling job.

Regards,

Nagaraj

Read only

0 Likes
1,321

Hi, Munur,

I suggest you that avoid these enhancements. Read Note 92550 - Stock inconsistency due to customer enhancement (exit, BAdI) to understand the reasons and the problems that you have in debug (because it is called with an FM in UPDATE TASK), and perhaps the same problems with locks.

If you go on thinking in use it, avoid call function modules, messages, lock/unlocks and call your z* in UPDATE TASK.

Regards,

Eduardo

Read only

Former Member
0 Likes
1,321

Hi Munur,

MB_DOCUMENT_UPDATE is called in update task so if you are debugging it in normal way it will not go in debugging

you have to switch on update debugging from your debugger. Go to Old debugger and switch on Update debugging and system debugging available under settings tab.

And For your issue I suugest you to create one update function module ( Put your whole logic in function module and give this FM type as Update in attribute select update radiobutton) and call this FM in BADI implematation by using

Call function Zfunction in update task. Read the F1 help for the same.

Regards,

Pawan

Read only

Former Member
0 Likes
1,321

Hi Pawan,

I coded all your suggestions but error occurs below. But there was no lock.!

"The plant data of the material 130860 is locked by the user MEBCIOGLU"

Best regards,

Munur

Read only

Former Member
0 Likes
1,321

Thanks