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

Implicite enhancement not triggering without debugging

praveenboss
Participant
0 Likes
2,612

HI Expert,

I  Created One Implicite Enhancement  In LMEGUICJI .

Method Save On "PO" Save .

It's Working Only When I Set Break point.

I try Every Think  but Cant Solve This.

Thanks & Regards.

7 REPLIES 7
Read only

SwadhinGhatuary
Active Contributor
0 Likes
1,565

Hi Praveen,

Some time sap need to update our standard tables, so think only after break in some place thinks are happened,personally i have such problems. So i suggest replace your break point with  wait for 1 sec in the same place of your  code.

hope this will help you

Read only

0 Likes
1,565

Swadhin,

What is the reason behind using WAIT statement to get the enhancement triggered ?

Sounds strange.

K.Kiran.

Read only

0 Likes
1,565

I second that, because WAIT is one of those mythical "solutions" that masks the underlying problem instead of addressing it. Often has to do with asynchronous updates, when the programmer is unable to fully understand the SAP logic he/she needs to use or extend.

And, the WAIT triggers implicit database commit (except in update function modules).

cheers

Jānis

Read only

Former Member
0 Likes
1,565

Hi Praveen,

Just want to share my experience and hope that may help you.

i) Normally the debugger wont stop if you put debugging in the implicit implementation.

ii) To ensure the enhancement code is getting execute:-

    a) Put the debugger point at any executable statement just before this enhancement

    b) Put infinite loop and check in SM50 or SM66 [Try only if you know how to debug the running      process]

   c) Set the breakpoint using the "BREAK-POINT" keyword.

Hope it will help you.

Thanks,

Gupta

Read only

nishantbansal91
Active Contributor
0 Likes
1,565

Hi Praveen,

Its strange, do one thing please Define message type 'A' at the start of the enhancement.

is there any condition that call your enhancement?

It might you are getting the data from the same table which SAP updates in the current session So while running at background mode your data is not updated, but when you are in  debugging time SAP updates the data and your enhancement is working fine.

Please give more us more clarity about your problem.

Thanks and Regards,

Nishant

Read only

1,565

Hi Nishant,

I Am using Implicite enhancement inside po save ( form METHOD_SAVE).

In LMEGUICJI.

Its Not working without BREAK-POINT  .

Now I am Using.


wait UP TO '1' SECONDS.

In enhancement.

It's Working..

Thanks.

Read only

0 Likes
1,565

Hi Praveen,

WAIT is sometimes used by developers to wait for a backround update process to finish. If a lot of update requests are already queued and all processes are busy, it may easily exceed 1 second. So using UP TO 1 seconds implements the source for a bug that will be extremely hard to track because you just can't reproduce the exact situation where it occured. On the other hand you will always have to add the 1 second to processing time - not very useful in mass processing.

The correct way would be to check the locks that have been set in the update process and wait for their release. Or put your exit development inside a function module and call it in update task.

Can't check with system now.

Regards, Clemens