2013 Jan 08 4:24 PM
Hello experts,
I have an abap code to generate a csv file on a linux server (trough transcation AL11)
On the decalarion part, I found this:
DATA : c_file_path(60),
c_file_path_d(12) VALUE 'XXX',
c_file_path_f(11) VALUE '/XX/XX/XX'.
Could someone tell me for what thoses declarations stand for?
Thanks.
Amine
2013 Jan 08 4:32 PM
Share the piece of code where c_file_path_d and
c_file_path_f are being used.
Regards,
Felipe
So looks everything is clear now, those variables are just use to compose the file name and directory to be used in file transfer.
Felipe.
2013 Jan 08 4:32 PM
Share the piece of code where c_file_path_d and
c_file_path_f are being used.
Regards,
Felipe
2013 Jan 08 5:04 PM
Hi Felipe,
Here it is:
CONCATENATE c_file_path_d sy-sysid c_file_path_f INTO c_file_path.
Amine
2013 Jan 08 5:29 PM
Also share the part of code where c_file_path is used or look for commad "call 'SYSTEM' id 'COMMAND' " or "OPEN DATASET"
Regards,
Felipe
2013 Jan 09 9:13 AM
Hi Felipe,
IF NOT c_file_path IS INITIAL.
CLEAR XXXXX.
CONCATENATE c_file_path 'XXX_'
code-company '_XXX_'
wa_tvarvc-low(4) wa_tvarvc-low+5(2) '.csv'
INTO fichier_sor.
OPEN DATASET fichier_sor FOR OUTPUT IN TEXT MODE ENCODING DEFAULT.
IF sy-subrc EQ 0.
file_out = 'XXX,XXX,XXX'.
TRANSFER file_out TO fichier_sor.
Sorry for the placeholders,
Thanks.
Amine
2013 Jan 09 11:58 AM
So looks everything is clear now, those variables are just use to compose the file name and directory to be used in file transfer.
Felipe.
2013 Jan 09 12:19 PM
2013 Jan 08 7:29 PM
Looks like a clumsy way of doing what you would normally do using logical filenames and the FILE transaction, e.g. incorporating a varying system ID (sy-sysid) in the path name for application server access.
By the way, could it be that you have the values of d and f mixed up in your first post? Are these placeholders or did you tell us the actual values?
Thomas
2013 Jan 09 9:09 AM
| User | Count |
|---|---|
| 6 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |