‎2006 Sep 27 7:15 PM
Hi all,
l like to modify the content of my internal table before sending line to dataset, and each field separate by coma (;).
example:
000000000000000700 ;KPC;KPC; 1; 1; 1
The file will be in text mode.
Thank's
Robert
‎2006 Sep 27 7:30 PM
concatenate all the fields in each record seperated by; this should do.
syntax concatenate f1 f2 f3... into v_str seperated by ';'.
regards,
Srini.
‎2006 Sep 27 7:25 PM
Hi,
Try this...
data: v_string type string.
DATA: begin of wa,
FIELD1 type char10 value '10112121',
field2 type char2 value 'ab',
field3 type char4 value 'asdf',
end of wa.
DATA: itab like wa occurs 0 with header line.
append wa to itab.
clear: wa.
field-symbols: <fs>.
loop at itab into wa.
clear: v_string.
DO 3 times.
ASSIGN component sy-index of structure wa
to <fs>.
if sy-index = 1.
concatenate v_string <fs> into v_string.
else.
concatenate v_string <fs> into v_string
separated by ';'.
endif.
enddo.
write: / v_string.
endloop.
Thanks,
Naren
‎2006 Sep 27 7:30 PM
concatenate all the fields in each record seperated by; this should do.
syntax concatenate f1 f2 f3... into v_str seperated by ';'.
regards,
Srini.
‎2006 Sep 27 7:39 PM
Hi,
You can you CONCATENATE Statment with SEPARETED BY ';'.
CONCATENATE F1 F2 F3 F4 F5 ... into ITAB-LINE SEPARETED BY ';'.
Regards
Sudheer