Could not deliver the file to SFTP in windows automation but log is showing success
Hello,
The file could not deliver to SFTP location but in Log file it is showing as success. I created a job through windows automation using below script.
cd %Root%
for /f %%a in (.\Jobs\Holidays.txt) do (
if %%a == %date:~-10,2%/%date:~-7,2%/%date:~-4% (
exit
)
)
@echo off
cd "C:\Program Files (x86)\WinSCP"
winscp.com /log=C:\pa\Jobs\BlS\Log\winscp.log /script=Prod.txt
exit
In Prod.txt I have used below.
option batch abort
option confirm off
open sftp://user:password@sername/ -privatekey="PuTTYPrivateKey.ppk"
put C:\TA\blS\BSN.txt /inbound/bsy/
EXIT
I have attached the log file. Could you please let me know what I am missing.
The file could not deliver to SFTP location but in Log file it is showing as success. I created a job through windows automation using below script.
cd %Root%
for /f %%a in (.\Jobs\Holidays.txt) do (
if %%a == %date:~-10,2%/%date:~-7,2%/%date:~-4% (
exit
)
)
@echo off
cd "C:\Program Files (x86)\WinSCP"
winscp.com /log=C:\pa\Jobs\BlS\Log\winscp.log /script=Prod.txt
exit
In Prod.txt I have used below.
option batch abort
option confirm off
open sftp://user:password@sername/ -privatekey="PuTTYPrivateKey.ppk"
put C:\TA\blS\BSN.txt /inbound/bsy/
EXIT
I have attached the log file. Could you please let me know what I am missing.