2019 Jul 02 10:48 AM
Hi,
I have a requirement where I have to retrieve 6 files based on set of names from a FTP destination.
These six files represent data for one plant and I am looping plant wise to get all files and updating in custom tables.
problem is connectivity gets disrupted after random GET file attempt in FTP_SERVER_TO_R3 and it keeps
processing and nothing else gets updated.
I have checked with network issues and didn't find any.
I have also tried reconnecting FTP_CONNECT after every loop iteration and still problem persist.
program gets stuck only at FTP_SERVER_TO_R3 and doesn't go forward.
Thanks guys
2019 Jul 02 12:48 PM
Did you try the pseudo-code below with FTP_DISCONNECT?
LOOP AT files ...
CALL FUNCTION 'FTP_CONNECT' ...
CALL FUNCTION 'FTP_SERVER_TO_R3' ...
CALL FUNCTION 'FTP_DISCONNECT' ...
ENDLOOP.
(edit: I replaced FTP_R3_TO_SERVER with FTP_SERVER_TO_R3 after Jagadeesh remark and Nida confirmation)
2019 Jul 02 1:59 PM
Please obfuscate your user, password, IP address, and so on
2019 Jul 04 3:32 PM
I think you should use ftp_server_to_r3 in place of ftp_r3_to_server because ftp_r3_to_server to place files in FTP directory ,iam not sure about it but just try with ftp_server_to_r3 once.
2019 Jul 04 6:24 PM
Hi Jagadesh,
Yes I used server to r3 FM and not the one mistakenly typed before.
Issue is same as mentioned ,processing stops randomly at FM before fetching file in CSV format.
I am only fetching files I know to be present in FTP location and all parameters passing into FM are correct as seen in debugger.
Regards
2019 Jul 09 3:43 PM
Run the standard programs RSFTP007 and RSFTP008 to make sure nothing wrong with your program.
I believe you no need to connect to FTP for each file. Is it happening for all the files or just happening randomly?