2008 Nov 25 8:43 AM
Moved to correct forum by moderator. Why did you post this in performance? Please take care in future to post in the correct forum.
Hi All,
I am uploading data into application server but i am not getting how to get file path.
Is there any FM for that?
Edited by: Matt on Nov 25, 2008 10:04 AM
2008 Nov 25 9:12 AM
hi,
to get the actual path from the logical path the function module is :
call function 'FILE_GET_NAME'
exporting
logical_filename = c_log_file
eleminate_blanks = 'X'
importing
file_name = h_f_dir
exceptions
file_not_found = 1
others = 2.
with this u can get the physical path in h_f_dir. concatenate the filename to this path.
then use the open dataset to open the file
Moved to correct forum by moderator. Why did you post this in performance? Please take care in future to post in the correct forum.
Hi All,
I am uploading data into application server but i am not getting how to get file path.
Is there any FM for that?
Edited by: Matt on Nov 25, 2008 10:04 AM
2008 Nov 25 8:49 AM
If you are already uploading data, you should already be knowing the file path!!
Open dataset <filepath>....
Regards,
Mohaiyuddin
2008 Nov 25 8:55 AM
I have to upload it.
i know open datset...........(AL11 for getting application server path)
i want the function module name.
2008 Nov 25 9:04 AM
Why did you post this in performance? Please take care in future to post in the correct forum.
2008 Nov 25 9:12 AM
hi,
to get the actual path from the logical path the function module is :
call function 'FILE_GET_NAME'
exporting
logical_filename = c_log_file
eleminate_blanks = 'X'
importing
file_name = h_f_dir
exceptions
file_not_found = 1
others = 2.
with this u can get the physical path in h_f_dir. concatenate the filename to this path.
then use the open dataset to open the file
2008 Nov 25 12:45 PM
You can use the following code.
CALL FUNCTION 'F4_DXFILENAME_TOPRECURSION'
EXPORTING
i_location_flag = 'A'
i_server = msxxlist-name
IMPORTING
o_path = v_filepath
EXCEPTIONS
rfc_error = 1
error_with_gui = 2
OTHERS = 3.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ELSE.
p_path = v_filepath "p_path is selection scr parameter.
CLEAR v_filepath.
ENDIF.
| User | Count |
|---|---|
| 6 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |