Skip to Content
0
Jan 08, 2008 at 10:34 AM

Work area problem

18 Views

Hi all,

I have 2 internal tables in my ABAP program.

report ztest123.

data: itab_1 type standard table of kna1,

data: wa_1 type kna1.

data: itab_2 TYPE STANDARD TABLE OF string,

data: wa_2 type string.

*populating data for itab_1

select * from kna1 into table itab_1 up to 50 rows.

*populating data for itab_2

wa_2 = 'kunnr'. append wa_2 to itab_2.

wa_2 = 'name1'. append wa_2 to itab_2.

wa_2 = 'ort01'. append wa_2 to itab_2.

*hard coded

loop at itab_1 into wa_1.

write:/ wa_1-kunnr, wa_1-name1, wa_1-ort01.

endloop.

My question is how to display value of only those fields of itab_1 which are stored in itab_2?

Thx,

Sukhbold