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

Runtime

Former Member
0 Likes
1,303

Hi,

I wrote a program to retrieve data from three different master data tables and put it into an internal table.

I got an error message saying - 'Maximum Runtime Exceeded.'

What does it mean?

Thanks.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,075

You will have to tune your program so that it doesn't take so much time to execute, there will be a limit set by the BASIS team for each program to execute. Check you SELECT statemenets / loops to decrease the execution time.

regards,

Ravi

Note : Please mark all the helpful answers

3 REPLIES 3
Read only

Former Member
0 Likes
1,075

Hi,

Check the following SAP note 740648...

Symptom

A work process can exceed the maximum runtime (specified by the "rdisp/max_wprun_time" profile parameter) without being cancelled.

Other terms

COMMIT WORK, TH_REDISPATCH, maximum runtime, WP_HOLD

Reason and Prerequisites

The reason for this is that the maximum runtime of a work process is not only reset to the value of rdisp/max_wprun_time if a new user (or more generally: a new task) is dispatched into the work process, but also if the current user performs actions that are associated with communication with the message server.

This is the case with enqueue operations, for example.

Solution

As of the patch level mentioned below, there is a profile parameter for Releases 46D, 620 and 640 that you can use to change the behavior of the timer in these cases: If you set the "rdisp/hold_keeps_time_slice" profile parameter to the "TRUE" value, then, after communication with the message server, the timer is set to the value rdisp/max_wprun_time minus the time that the process consumed for this task up to now. This solves the problem in most cases.

However, since the explosion of the measurement of time is in the area of seconds, operations that occur between message server operations and require less than one second may lead to an extension of the overall runtime.

Parameters Values Default

rdisp/hold_keeps_time_slice FALSE, TRUE FALSE

As of Basis Release 7.0, the behavior described above is standard behavior and can no longer be changed. The parameter exists in other releases with the following patch levels:

46D: 1848

620: 1502

640: 18

Thanks and Regards,

Bharat Kumar Reddy.V

Read only

Former Member
0 Likes
1,076

You will have to tune your program so that it doesn't take so much time to execute, there will be a limit set by the BASIS team for each program to execute. Check you SELECT statemenets / loops to decrease the execution time.

regards,

Ravi

Note : Please mark all the helpful answers

Read only

0 Likes
1,075

Your program is going to short dump due to lack of proper code optimization and performance issues as others have also stated.

In addition to do the runtime analysis , you can make use of following also:

1. You can make use of SAP Code Inspector ( transaction code : SCI) to check your program. It will give you an idea how to optimize your select queries and detailed analysis of other errors/ warnings whihc will help you to fine tune your program.

2. The runtime analysis is also a good option because it will tell you which table is highly being used and then accordingly you can optimize your code.

3. Select single is always a better option than using select *. Moreover if you know which data actuallu to retreive , you should use obly those fields yto retreive.

4. Avoid using nested select statements and nested loops as far as possible.

Hope these points help you analyze your program in a better way and give you a certain solution to optimize your code.

<b>Updation of the timeout limit is task of BASIS.</b>

In Tcode : RZ10, you can maintain systme parameters.

The parameter name is rdisp/max_wprun_time. If it not maintained in the profile it will be default 10 mins(600 seconds) as SAP has recommended.

Make sure about your system before changing that.

ALSO CHECK OUT WITH THESE LINKS

http://sap.ittoolbox.com/groups/technical-functional/SAP-R3-DEV/timeout-in-abap-debugger-560635

http://sap.ittoolbox.com/groups/technical-functional/SAP-R3-DEV/timeout-in-abap-debugger-560756