Topic "Job Success but files did not copy"

Author Message
[View user's profile]

Joined: 2013-06-28
Posts: 2
Good Morning,
I have a SSIS package, which executes a winscp script. On a remote server i have two folders and on under folder (PartyCodes) i have a .csv file (codes.csv) that i need to copy to local drive and delete the file.
I have the following script which runs but doesn't copies the file, please advice where am going wrong.
NOTE: When i executed the package first i got the following error ([Execute Process Task] Error: In Executing "C:\Program Files (x86)\WinSCP\" "-script=C:\winsftpscriptCAR.txt" at "C:\Program Files (x86)\WinSCP", The process exit code was "1" while the expected was "0".0. So changed the task properties (FailTaskIfReturncodeisnotcorrectvalue to FALSE).
Now the job is success but not copying the files , my code
option batch on
option confirm off
open sftp://userid:pwd@servername:22 -hostkey="ssh-rsa 2048 xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx"
cd .
option transfer binary
get -preservetime *.csv F:\FTPShare\ftp\CARDownloads\

Please need help
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 26730
Location: Prague, Czechia
Please attach a full log file showing the problem (using the latest version of WinSCP).

To generate log file, use /log=path_to_log_file command-line argument. Submit the log with your post as an attachment. Note that passwords and passphrases not stored in the log. You may want to remove other data you consider sensitive though, such as host names, IP addresses, account names or file names (unless they are relevant to the problem). If you do not want to post the log publicly, you can mark the attachment as private.
[View user's profile]

Joined: 2013-06-28
Posts: 2
Thanks Prikryl. I fixed the error. However i can connect manually from one server but not from the other server. Any ideas please?

You can post new topics in this forum


What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!


About donations

$9   $19   $49   $99

About donations


WinSCP Privacy Policy

WinSCP License