Skip to Content
0
Former Member
Jun 19, 2008 at 10:16 AM

plz...chk this.

48 Views

hi,

can any one tell me, this is correct or not..?

check not itab2[] is initial.

select konh~knumh

konh~kosrt from konh join konp

on konhknumh = konpknumh

into corresponding fields of

table itab3

for all entries in itab2

where konh~knumh = itab2-knumh and

kosrt in srchterm and

konp~loevm_ko = 'X'.

loop at itab3 into wa_itab3.

read table itab2 into wa_itab2 with key knumh = wa_itab3-knumh.

if sy-subrc = 0.

move:

wa_itab2-vbeln to wa_itab4-vbeln,

wa_itab2-posnr to wa_itab4-posnr,

wa_itab2-matnr to wa_itab4-matnr,

wa_itab3-knumh to wa_itab4-knumh,

wa_itab3-kosrt to wa_itab4-kosrt.

append wa_itab4 to itab4.

endif.

endloop.

thanks