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

Problem Reading Flat File from Application server

Former Member
0 Likes
322

Hi All,

I want to upload a Flat File which is having a Line Length of 3000.

While uploading it to Application server , only upto 555 length it is getting uploaded .

i am using the code :

DATA: BEGIN OF TB_DATA OCCURS 0,

LINE(3000),

END OF TB_DATA.

*----Uploading the flat file from the Local drive using FM "UPLOAD".

OPEN DATASET TB_FILENAM-DATA FOR OUTPUT IN TEXT MODE." ENCODING DEFAULT.

IF SY-SUBRC NE 0.

WRITE:/ 'Unable to open file:', TB_FILENAM-DATA.

ELSE.

LOOP AT TB_DATA.

TRANSFER TB_DATA TO TB_FILENAM-DATA.

ENDLOOP.

ENDIF.

CLOSE DATASET TB_FILENAM-DATA.

What could be the problem?

Could it be due to any Configuration Problem?

Waiting for your replies.

Thanks and Regards.

Suki

1 REPLY 1
Read only

Former Member
0 Likes
294

Your code looks OK, but you may have touble displaying the full width. Try:

WRITE: /001 TB_FILENAM-DATA+555.

(And don't forget to append your ITAB after each read.)

Rob