12-17-2008 12:42 PM
Hi all,
pls tell me how to write a file to application server AL11 using ABAP
12-17-2008 1:10 PM
Hi,
To send a file to Application Server you have to use below code.
OPEN DATASET v_filepath FOR OUTPUT IN TEXT MODE ENCODING DEFAULT.
TRANSFER v_data TO v_filepath.
CLOSE DATASET v_filepath.
v_filepath is the file path where file is to be placed in Application server.
Hope this may be helpful.
Regards,
Sravanthi
12-17-2008 1:09 PM
Hello Friend,
Search in SDN you will find the solution. Innumerable posts are available on this
BR,
Suhas
12-17-2008 1:10 PM
Hi,
To send a file to Application Server you have to use below code.
OPEN DATASET v_filepath FOR OUTPUT IN TEXT MODE ENCODING DEFAULT.
TRANSFER v_data TO v_filepath.
CLOSE DATASET v_filepath.
v_filepath is the file path where file is to be placed in Application server.
Hope this may be helpful.
Regards,
Sravanthi
12-17-2008 1:11 PM
Hi
See the help for the statament OPEN DATASET, TRANSFER and CLOSE DATASET:
OPEN DATASET <FILE NAME> .....<----- Open file
TRANSFER <data> to <FILE NAME> <---- Download the data to file
CLOSE DATASET <FILE NAME>. <----- Close file
Max
12-17-2008 1:16 PM
Hi U can use the function module
C13Z_FILE_UPLOAD_ASCII
if you press c13z there willbe somme function modules.
Just go through i hope above one may help you.
Thanks
12-17-2008 1:17 PM
Hello,
You have to do the following 3 steps.
1. OPEN DATASET
2. TRANSFER
3. CLOSE DATASET
you can write the following code.
PARAMETERS: P_FILE LIKE RLGRAP-FILENAME OBLIGATORY . " your path on you
"application server
*To open the dataset
OPEN DATASET P_FILE FOR OUTPUT IN TEXT MODE.
*To write data to a file on your application sever
LOOP AT TBL_FINAL. " TBL_FINAL contains data to be sent to file
TRANSFER TBL_FINAL TO P_FILE.
ENDLOOP.
Close the data set you have opened earlier
CLOSE DATASET P_FILE.
Regards
Arindam
04-28-2015 10:54 AM
Hi Abhishek,
Could you please give me an idea of how v_data to be declared ? is it the final internal table ??
Thanks.
04-28-2015 12:10 PM
v_data must be a flat structure, normally a table work area though not necessary.
This post is over six years old.
08-03-2015 7:27 AM
Hi,
use standard reports for uploading and downloading,
CG3Y - Downloading file from application server
CG3Z - Uploading file to application server
- Regards,
Kasif