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

Regarding 'Select .... for all entries' statement

Former Member
0 Likes
776

Hi experts,

Can anyone suggest me that whether we can use two internal tables in 'Select .... for all entries' statement?

1 ACCEPTED SOLUTION
Read only

JozsefSzikszai
Active Contributor
0 Likes
751

no, it is not possible.

no, it is not possible.

4 REPLIES 4
Read only

JozsefSzikszai
Active Contributor
0 Likes
752

no, it is not possible.

Read only

Former Member
0 Likes
751

Hi,

I think using two internal tables in select....for all enteries in table degrade the performance in case there is large data.

so better is use two separate select statements for two tables.

Regards

Rajesh Kumar

Read only

Former Member
0 Likes
751

hi,

You cannot have two driver internal tables in the FOR ALL ENTRIES..

thanks

Read only

Former Member
0 Likes
751

Hi,

You can use ranges instead of second for all entries.

Eg:

Say for example i need to write selec statement using fields from two int tables in where conidition namely itab1, itab2.

RANGES: r_vbeln FOR wa_tab1-vbeln.

LOOP AT itab1 INTO wa_tab1.

  r_vbeln-sign = 'I'.
  r_vbeln-option = 'EQ'.
  r_vbeln-low = wa_tab1-vbeln.
  APPEND r_vbeln.
ENDLOOP.

SELECT * FROM vbap INTO TABLE itab3
FOR ALL ENTRIES IN itab2
WHERE vbeln IN r_vbeln "range contains all vbeln from the table itab1
AND matwa = itab2-matwa.

Hope this helps you.

Regards,

Manoj Kumar P