2008 Mar 10 10:49 AM
Hi all,
I have a requirement to select all files with the same file format I.e i have created no of files with same name but different time stamps addition , now i want to select all the fiels and read the data into an internal table and sort them on the user requirement, I am using FM -
/SAPDMC/LSM_F4_SERVER_FILE to get single file name, i should also give the option on the selection screen for the user to select the file range I.e form which to which the sorting should be done.
could anybody suggest me the function module which selects all the file names .
Regards,
Sre.
Edited by: Alvaro Tejada Galindo on Mar 10, 2008 4:49 PM
2008 Mar 10 10:55 AM
Hi,
PARAMETER: p_fdir type pfeflnamel DEFAULT '/usr/sap/tmp'.
data: begin of it_filedir occurs 10.
include structure salfldir.
data: end of it_filedir.
************************************************************************
*START-OF-SELECTION
START-OF-SELECTION.
Get Current Directory Listing for OUT Dir
call function 'RZL_READ_DIR_LOCAL'
exporting
name = p_fdir
tables
file_tbl = it_filedir.
List of files are contained within table it_filedir
loop at it_filedir.
write: / it_filedir-NAME.
endloop.
Regards,
Omkaram.
2008 Mar 10 2:22 PM
2008 Mar 10 11:04 AM
Hi,
FILE_READ_AND_CONVERT_SAP_DATA: Uploads the file from either presentation or application server into an internal table
SUBST_GET_FILE_LIST: To get the list of files from Application Server.
Regards,
Priya.