Hi Gurus,
I have a structure <lw_rtab_wa> with the below fields:
RECNO I(4)
DOC_NUMBER C(10)
S_ORD_ITM N(6)
CH_ON D(8)
CREATEDON D(8)
There is also a field symbol <LT_RTAB> which has the below structure:
RECNO I(4)
DOC_NUMBER C(20)
S_ORD_ITM N(12)
CH_ON D(8)
CREATEDON D(8)
Basically the lengths of DOC_NUMBER & S_ORD_ITM are different. When I use the statement
DO.
ASSIGN COMPONENT sy-index OF STRUCTURE <lw_rtab_wa> TO <lt_rtab>.
IF sy-subrc NE 0.
NEW-LINE. " Shift Cursor to next line
EXIT. " EXIT to next work area
ENDIF. " IF sy-subrc NE 0.
ENDDO.
I get the message ASSIGN_TYPE_CONFLICT.
If I just try to use APPEND <LW_RTAB_WA> to <LT_RTAB>, I see that the data in <LT_RTAB> is all clubbed together in the first 3 columns as lengths of DOC_NUMBER & S_ORD_ITM are bigger in <LT_RTAB>.
How do I use the APPEND statement but also make sure that data is split accurately into individual columns and not clubbed together?
Thanks
Arvind