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

Upload file to application server

Former Member
0 Likes
413

I am uploading a file from presentation server to the application server thru tcode

CG3Z . But the path i need to give for the application server is not accomodating in the field given for writing the application server path where the file needs to be uploading . Some of the characters are missed out coz the field length is small

Is there any other way to do this . kindly help

2 REPLIES 2
Read only

Former Member
0 Likes
374

Use this code

REPORT ZGILL_AS message-id rp .

parameters: P_DSNI(75) TYPE C MODIF ID ABG DEFAULT

'/usr/local/sapdata/amit.dat' LOWER CASE.

data: begin of itab occurs 0,

pernr(8),

sp1(1) value ',',

werks(4),

sp2(1) value ',',

persg(1),

sp3(1) value ',',

persk(2),

end of itab.

OPEN DATASET P_DSNI FOR OUTPUT IN LEGACY TEXT MODE.

PERFORM FETCH_DATA.

&----


*& Form FETCH_DATA

&----


  • text

----


  • --> p1 text

  • <-- p2 text

----


FORM FETCH_DATA .

SELECT * FROM PA0001 WHERE PERNR IN S_PERNR.

MOVE-CORRESPONDING PA0001 TO ITAB.

TRANSFER ITAB TO P_DSNI.

APPEND ITAB.

ENDSELECT.

CLOSE DATASET P_DSNI.

ENDFORM. " FETCH_DATA

Read only

Former Member
0 Likes
374

check the function modules...

DOWNLOAD

UPLOAD