Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

delimiter

Former Member
0 Likes
581

Hi ,

Please help me in this.

When extracting file from program on that time it must be delimiter extracted file (delimeter";" semicolon).

For this what is the logic please help me.

Thanks

Hi ,

Please help me in this.

When extracting file from program on that time it must be delimiter extracted file (delimeter";" semicolon).

For this what is the logic please help me.

Thanks

3 REPLIES 3
Read only

Former Member
0 Likes
556

Hi,

Use 'Split' Statement but i don't think this would be required since the FM which you use to extract the data does that if required then you can use this 'SPLIT' statement.

Thanks,

Prashanth

Read only

Former Member
0 Likes
556

see the following ex code to read ',' delemeted file.

OPEN DATASET g_file FOR INPUT IN TEXT MODE

ENCODING DEFAULT

IGNORING CONVERSION ERRORS.

IF SY-SUBRC EQ 0.

DO.

READ DATASET g_file INTO FILE.

if sy-subrc = 0.

split FILE at ',' into ITAB-SOL_DOCNO ITAB-SOL_DOCDT

ITAB-WERKS ITAB-LGORT ITAB-MATNR ITAB-ERFMG .

else.

exit.

endif.

APPEND ITAB.

CLEAR ITAB.

ENDDO.

ENDIF.

Read only

sreeramkumar_madisetty
Active Contributor
0 Likes
556

Hi

OPEN DATASET g_file FOR INPUT IN TEXT MODE ENCODING DEFAULT

IF SY-SUBRC EQ 0.

READ DATASET g_file INTO FILE.

if sy-subrc = 0.

split FILE at ',' into itab.

endif.

Regards,

kumar