Skip to Content
0
Former Member
Aug 08, 2016 at 05:10 AM

Query from tables KNVV and TVV5T consumed huge memory

132 Views

Hi ABAP Experts,

I have a routine to extract Customer Group 5 for Customer numbers based on their sales org, dist channel, division from tables KNVV and TVV5T. However, the SQL query seemed consume very huge memory. I really appreciate if you guys can advise some ideas and solution to optimize the query ?

The number of entries in KNVV are only 8831.

Here is the code and the trace.

Another routine also using FOR ALL ENTRIES IN lt_vbak but the query works fine.

SQL Trace between KNVV and VBPA is here.

Thanks and regards,

Danny

Attachments

Capture1.PNG (29.0 kB)
Capture2.PNG (22.9 kB)
Capture3.PNG (108.8 kB)