‎2008 Oct 30 12:53 PM
hi
in an Internal table i have
1.no
2.name
3.value
fields.
in loop i have only one no but multiple name and value for that no !
how to reterive that name and value.
loop at itab into wa.
write: no.
loop at itab into wa.
write:name.
write:value.
endloop.
endloop.
is is correct ???????
no.101 --->name aa value 90
bb 89
cc 77
‎2008 Oct 30 12:59 PM
Do like this :
Loop at itab.
at new num.
write itab-num.
endat.
write itab-name
write itab-value.
endloop.
regards,
Advait
‎2008 Oct 30 12:58 PM
‎2008 Oct 30 12:59 PM
Do like this :
Loop at itab.
at new num.
write itab-num.
endat.
write itab-name
write itab-value.
endloop.
regards,
Advait
‎2008 Oct 30 1:02 PM
Hi Dharma,
Do it in this way.
TYPES: BEGIN OF TY_TAB,
no(18) TYPE C,
name(30) TYPE C,
value (10) TYPE C,
END OF TY_TAB.
DATA: IT_TAB1 TYPE STANDARD TABLE OF TY_TAB WITH HEADER LINES.
DATA: IT_TAB2 TYPE STANDARD TABLE OF TY_TAB WITH HEADER LINES.l
"--------> Now populate the internal table IT_TAB1.
IT_TAB2[] = IT_TAB1[].
SORT IT_TAB1 BY NO.
LOOP AT IT_TAB1.
READ TABLE IT_TAB2 WITH KEY NO = IT_TAB2-NO.
IF SY-SUBRC = 0.
WRITE:/ IT_TAB2-NO, IT_TAB2-NAME, IT_TAB2-VALUE.
DELETE IT_TAB2 INDEX SY-TABIX.
ENDIF.
ENDLOOP.
Thanks,
Chidanand
‎2008 Oct 30 1:03 PM
‎2008 Oct 30 1:12 PM
Hi Dharma ,
If you are done with this issue , so please close this thread
Thanks & Regards