Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

problem in for all entries

hi abap gurus,

I hav 2 internal tables it1,it2.

it2 has the same structure of it1 except it has one additional field(percent).

I hav moved the contents from it1 to it2 using move corresponding.now i want to populate that percent field from the database table X for all the entries in it2.

I used the following query.but it has not given the required output.

select percent

into corresponding fields of table it2

from X

for all entries in it2

where code = it2_code.

pls help me.

Tags:
replied

hi,

use ony it2.

and create another internal table itab3 with code and percent field,

then use select data into itab3 for all entries in itab2

where code = itab2-code.

then

loop at itab2.

read table itab3 with key code = itab2-code.

if sy-subrc = 0.

itab2-percent = itab3-percent.

endif.

modify itab2 transporting percent.

endloop.

hope it will help you...

Regards

Meet

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question