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

exception error in function module MC_EXCEPTION_EVENT

Former Member
0 Likes
1,720

Hi All,

I am facing issue with exception raised from Function Module MC_EXCEPTION_EVENT.

This function module is being called inside BAPI BAPI_TRANSACTION_COMMIT from COMMIT WORK statement.


Throwing error "No event-driven analysis for program ".

please share your thoughts to suppress/bi-pass this exception.

Thanks,

Rajendra Nagiri

1 ACCEPTED SOLUTION
Read only

matt
Active Contributor
0 Likes
1,678

You do not want to suppress nor bypass the error. This is just covering up the symptom. You want to find out what is causing it, and then address that cause - this curing the problem. I hope you understand the difference.

For a meaningful answer you must supply more information about the context. I assume you are not simply calling BAPI_TRANSACTION_COMMIT as the only action in your program? Also, have you search for a note, to see if this error has already be encountered and addressed?

8 REPLIES 8
Read only

matt
Active Contributor
0 Likes
1,679

You do not want to suppress nor bypass the error. This is just covering up the symptom. You want to find out what is causing it, and then address that cause - this curing the problem. I hope you understand the difference.

For a meaningful answer you must supply more information about the context. I assume you are not simply calling BAPI_TRANSACTION_COMMIT as the only action in your program? Also, have you search for a note, to see if this error has already be encountered and addressed?

Read only

Former Member
0 Likes
1,678

hi Matthew,

i am trying to update MFBF via 'Z' BAPI.

after BAPI i am calling BAPI_TRANSACTION_COMMIT .

the message is not stopping any process. but if it is of some meaing like "document not posted" or " data updated successfully" that will be fine..

"No event-driven analysis for program"  has no meaning to understand..

Thanks,

Rajendra Nagiri

Read only

matt
Active Contributor
0 Likes
1,678

The problem is not in fact caused by BAPI_TRANSACTION_COMMIT. What is happening is that when the commit happens, the form UPDATE_FROM_INT in LMCB1F10 is called. This is because mcinf_update_all in LMCB1F10 has this piece of code:

PERFORM update_from_int ON COMMIT.


Therefore the problem lies firmly within the Inventory Controlling module, specifically in the updating of Inventory Controlling Statistics.


Looking at the code within the form issuing the error, it looks like a program isn't registered in some configuration table. Try re-running your test and find out what the value of prog_tab-fprof is a the place the error in thrown. I'd bet that it is a Z program - perhaps your "Z" Bapi.


No, you've hinted that you've copied a standard BAPI into the Z name space for your own purposes. Not only does this cause problems such as you are experiencing, it is also a profoundly bad thing to do. The reasons it is bad are:


1. Patches and fixes to the original BAPI won't get applied. This can lead to your Z-bapi becoming syntactically incorrect, or even having (over time) incorrect logic, leading to corruption of your data.

2. It is exactly the same as writing your own code to update standard SAP tables. If that happens, then the terms of support with SAP will almost certainly have been broken, and your client/employer will have to pay $$$$$$$ to fix it.


I strongly recommend you find another route to address the business requirement. Modifying the standard is a safer approach than cloning a standard program. Perhaps if you shared why you've made a copy, suggestions could be made as to safer ways to achieve the requirement.




Read only

Former Member
0 Likes
1,678

Hi Matthew,

All the places and form names you've are PERFECT match with my requirement.

This is the only place I am getting the error.


Also I am  not using any Z bapi , in Z inbound IDOC function module I am caling BAPI "BAPI_REPMANCONF1_CREATE_MTS" (Execute Backflush in Stock)and then calling

BAPI_TRANSACTION_COMMIT( for commit).


i've verified the below notes also, but no clues..

390918 - IS-M/AM: LIS deadlock in update / dump with order

376750 - LIS: deadlocks due to unsorted PROGTAB


do I need to implement any notes for this issue.

share your thoughts..


Thanks,

Rajendra Nagiri

Read only

matt
Active Contributor
0 Likes
1,678

It was your reference to Z BAPI above that misled me.

OK - so you're just using the BAPI directly. Nonetheless, place a breakpoint at the indicated place and see what the value is. It still looks to me like missing configuration.

Read only

Former Member
0 Likes
1,678

Matthew,

apologies for misleading you.

below is the exception function module causing problem. sy-subrc is always 1.

the FM has an exception inside it.

Thanks,

Rajendra Nagiri

Read only

matt
Active Contributor
0 Likes
1,678

" place a breakpoint at the indicated place and see what the value is."

Read only

Former Member
0 Likes
1,678

Hi,

your first step should be to determine if the error/exception is correct. Usually there is a valid reason for preventing you to update masterdata.

If you find the reason to be invalid then you should search OSS to see if this problem is acknowledged and if there is a fix for it, this happens sometimes.

You never try to force your way through eceptions, because that can lead to corrupt master data, which can and will lead to huge losses (think Millions) for the company that you are working for and you don't want that to happen.

Kind regards, Rob Dielemans