07-23-2012 7:48 PM
Dear Experts,
In an FTP SERVER ,I have a file say x.txt located under the folder "Incoming".
I want to move this file from the "Incoming" directory to "Test" directory.
"Incoming" and "Test" directory are on the same level.
Is there a command to do it with "FTP_command" in ABAP
Thanks
K
07-23-2012 8:47 PM
Hi Fathima,
Did you search the forum? This has been discussed a couple of times.
http://scn.sap.com/thread/1773085
Regards,
Shravan
04-22-2013 6:54 PM
Hi,
I have the same issue. Did you find an answer for this?
Thanks in advance.
Regards,
Sónia Gonçalves
04-23-2013 5:14 AM
Hi,
Just check the prog RSFTP004 for FTP copy and also check progs
RSFTP002
RSFTP003
RSFTP005
RSFTP006
RSFTP007
RSFTP008
RSFTP009
RSFTP011
Regards,
Ramesh.
04-23-2013 9:47 AM
Hi,
Thanks for your reply.
But I would like to know if there's another FTP command to do this, either than copy and delete.
I read that command "RENAME" could probably do this. Is that right?
Thanks.
Best regards,
Sónia Gonçalves
04-23-2013 1:38 PM
Hello.
Yes, u can move the files to another directory. The way to do it is using RENAME command.
I have done this, have a look this code
"l_fname2 contains the file name.
CONCATENATE 'TEST/' l_fname2 INTO l_string_error. " New directory
CONCATENATE 'rename' l_fname2 l_string_error INTO l_command SEPARATED BY space.
CALL FUNCTION 'FTP_COMMAND'
EXPORTING
handle = mi_handle
command = l_command
TABLES
data = mtab_data
EXCEPTIONS
tcpip_error = 1
command_error = 2
data_error = 3
OTHERS = 4.
Regards