Supply Chain Management Blogs by SAP
Expand your SAP SCM knowledge and stay informed about supply chain management technology and solutions with blog posts by SAP. Follow and stay connected.
cancel
Showing results for 
Search instead for 
Did you mean: 
stefan_foerster
Explorer

Everyone, who debugs in TM, faced the situation many times: any BOPF call returns an object, which is deeply nested, e.g. eo_change or eo_message. This post is intended to suggest a way to save time investigating.

For example: In debugger you execute a BOPF call (retrieve, do_action or even save transaction) and you get failed keys or a rejected flag. As a next step you may want to check the collected messages in the eo_message object.

You doublecklick the message object and see a high number of collected messages in the attribute mt_message:

In order to learn more about the collected messages you unfortunately need to doublecklick each message reference of each line in this table, find the referenced message ID and number, open a separate session to lookup the text in SE91 and then you know whether this message is relevant for your investigation:

But, sure, you know all those steps and got used to it. Why then this blog post?

Wouldn't it be nice to see all those messages in the debugger right away?

Most of us do actually not know that the BOPF colleagues provided a helping hand here already.

In debugger, include the tool section "Script Wrapper". On the very right side, push the button 'New Tool'.

In this new section load the existing debugger script '/BOBF/TOOL_DEBUGGER_SCRIPT_F'.

Into the BOPF Framework Object field you put your local object variable, which imported the returned eo_message parameter, and then you click on 'Start'.

And what a nice relief! You can see all the messages right away in the debugger and there is no need to spend so much time to navigate through all the message references to pull out the texts from SE91 anymore.

There is only a small shortcoming. Once you identified a message to be relevant for your investigation, you actually want to set a break-point at the place where the message is raised. From SE91 you usually do a where-used ... etc.

Unfortunately the available debugger script does not list the message ID and number.

But no worries, here is how to add those two columns:

In SE38 just copy the program '/BOBF/TOOL_DEBUGGER_SCRIPT_F' and in your own local Z* program you do the following adjustments:

   (This is a screenshot of version management's comparison feature. You need to insert the white lines.)

And look at that. In the debugger you get right away all the message IDs and numbers and texts of all the referenced messages of the eo_message object...

By the way, the available script also handles other BOPF Framework objects, like eo_change.

Have fun saving time...

3 Comments