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

Nested Loop

Former Member
0 Likes
475

Hi ALL,

For every record in Outer loop i have to loop through internal table with date range to get total (from all the records that fall in date range) , i could do this but the problem is taking longtime 15min per data set, is there way we can improve . Though i have optimized the code to any extent but time remains same inspite clearing tables. Below are the SM50 Details if helps.

Roll In 0 0

Roll Out 0 0

Roll 229,376 (Bytes)

Page 24,576 (Bytes)

Memory (Total) 96,395,984 (Bytes)

Memory(Total Private) 0 (Bytes)

Memory (used) 88,013,664 (Bytes)

Memory (Max. Transaction) 96,395,984 (Bytes)

Memory (Max. Dialog Step) 96,395,984 (Bytes)

Regards

Kunal

1 ACCEPTED SOLUTION
Read only

ThomasZloch
Active Contributor
0 Likes
439

Check with SE30 where your code spends the time, make sure you use a TYPE SORTED TABLE for the inner loop, sort key according to the where-condition.

Thomas

3 REPLIES 3
Read only

Former Member
0 Likes
439

I feel it would be better if you could post your code, just in case if there is a room to improve the performance in the coding which you might not be aware of.

Read only

ThomasZloch
Active Contributor
0 Likes
440

Check with SE30 where your code spends the time, make sure you use a TYPE SORTED TABLE for the inner loop, sort key according to the where-condition.

Thomas

Read only

Former Member
0 Likes
439

if both tables are as bellow reply you can use this logic

[|]

Thanks

nafran