Reputation: 21
I need an explanation how to pass arguments to WinSCP in SSIS Execute process task.
I want to download a latest file using SFTP on everyday basis.
I am able to connect to Remote Server using WinSCP in SSIS.
FTP Task steps:
http://winscp.net/eng/docs/guide_ssis
I followed the steps as in:
http://winscp.net/eng/docs/scripting
My Problem is:
I want to pass parameter to my WinSCP Script.
My script has command get "%1%"
.
Complete Script:
option batch abort
option confirm off
open sftp://usename:[email protected]
option transfer binary
cd /root
get "%1%" C:\Data\
close
exit
On my Execute Process Task editor, I am passing argument *20120817*.xml
as below, but it is not working:
/script=scriptB.txt \*20120817\*.xml
Upvotes: 2
Views: 5145
Reputation: 202168
You are missing the /parameter
switch:
/script=scriptB.txt /parameter *20120817*.xml
Refer to:
https://winscp.net/eng/docs/commandline#scripting
Upvotes: 3