File not getting download
Here is my script
@echo off
"E:\APOMS_BAT\MY\CA\autosys\ftp\WinSCP.com" ^
/command ^
"open sftp://avon_dc:oefjp459@liason2.avon.com/ -hostkey=""ssh-dss 1024 /A=""" ^
"cd /Distribution/AXFILES/RX/" ^
"mv SOD*.xml>0K<5N *.xmltmp" ^
"lcd E:\Agility\RX" ^
"get SOD_*.xmltmp SOD_*.xml" ^
"cd /Distribution/AXFILES/RX" ^
"mv SOD_*.xmltmp /Distribution/AXFILES/RXFiles/" ^
"exit"
set WINSCP_RESULT=%ERRORLEVEL%
if %WINSCP_RESULT% equ 0 (
echo Success
) else (
echo Error
)
exit /b %WINSCP_RESULT%
Issue
mv SOD*.xml>0K<5N *.xmltmp -> Rename is done
Download did not happen
mv SOD_*.xmltmp /Distribution/AXFILES/RXFiles/ -> is done
Log -
SOA_AGBJ53399109_20190625_122751 - Rename, download and move happen successfully
SOD_AGBJ53399109_20190625_426441 - Rename, download and move happen successfully
SOD_AGBJ53399109_20190625_459999, did not been download as showed below - Please HELP on this
SOD_AGBJ53399109_20190625_713865 - Rename, download and move happen successfully
Detail Log as below
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOA_PROCESS_DAILY_2491818-1.out:11:SOA_AGBJ53399109_20190625_122751.xml
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOA_PROCESS_DAILY_2491818-1.out:27:SOA_AGBJ53399109_20190625_122751.xmltmp | 1002 B | 0.0 KB/s | binary | 100%
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOA_PROCESS_DAILY_2491818-1.out:41:SOA_AGBJ53399109_20190625_122751.xmltmp
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2492036-1.out:13:SOD_AGBJ53399109_20190625_426441.xml
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2492036-1.out:47:SOD_AGBJ53399109_20190625_426441.xmltmp | 1 KB | 1.2 KB/s | binary | 100%
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2492036-1.out:80:SOD_AGBJ53399109_20190625_426441.xmltmp
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2492698-1.out:11:SOD_AGBJ53399109_20190625_459999.xml
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2492698-1.out:19:SOD_AGBJ53399109_20190625_459999.xmltmp
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2495598-1.out:14:SOD_AGBJ53399109_20190625_713865.xml
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2495598-1.out:126:SOD_AGBJ53399109_20190625_713865.xmltmp | 9 KB | 19.6 KB/s | binary | 100%
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2495598-1.out:770:SOD_AGBJ53399109_20190625_713865.xmltmp
@echo off
"E:\APOMS_BAT\MY\CA\autosys\ftp\WinSCP.com" ^
/command ^
"open sftp://avon_dc:oefjp459@liason2.avon.com/ -hostkey=""ssh-dss 1024 /A=""" ^
"cd /Distribution/AXFILES/RX/" ^
"mv SOD*.xml>0K<5N *.xmltmp" ^
"lcd E:\Agility\RX" ^
"get SOD_*.xmltmp SOD_*.xml" ^
"cd /Distribution/AXFILES/RX" ^
"mv SOD_*.xmltmp /Distribution/AXFILES/RXFiles/" ^
"exit"
set WINSCP_RESULT=%ERRORLEVEL%
if %WINSCP_RESULT% equ 0 (
echo Success
) else (
echo Error
)
exit /b %WINSCP_RESULT%
Issue
mv SOD*.xml>0K<5N *.xmltmp -> Rename is done
Download did not happen
mv SOD_*.xmltmp /Distribution/AXFILES/RXFiles/ -> is done
Log -
SOA_AGBJ53399109_20190625_122751 - Rename, download and move happen successfully
SOD_AGBJ53399109_20190625_426441 - Rename, download and move happen successfully
SOD_AGBJ53399109_20190625_459999, did not been download as showed below - Please HELP on this
SOD_AGBJ53399109_20190625_713865 - Rename, download and move happen successfully
Detail Log as below
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOA_PROCESS_DAILY_2491818-1.out:11:SOA_AGBJ53399109_20190625_122751.xml
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOA_PROCESS_DAILY_2491818-1.out:27:SOA_AGBJ53399109_20190625_122751.xmltmp | 1002 B | 0.0 KB/s | binary | 100%
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOA_PROCESS_DAILY_2491818-1.out:41:SOA_AGBJ53399109_20190625_122751.xmltmp
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2492036-1.out:13:SOD_AGBJ53399109_20190625_426441.xml
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2492036-1.out:47:SOD_AGBJ53399109_20190625_426441.xmltmp | 1 KB | 1.2 KB/s | binary | 100%
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2492036-1.out:80:SOD_AGBJ53399109_20190625_426441.xmltmp
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2492698-1.out:11:SOD_AGBJ53399109_20190625_459999.xml
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2492698-1.out:19:SOD_AGBJ53399109_20190625_459999.xmltmp
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2495598-1.out:14:SOD_AGBJ53399109_20190625_713865.xml
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2495598-1.out:126:SOD_AGBJ53399109_20190625_713865.xmltmp | 9 KB | 19.6 KB/s | binary | 100%
E:\Temp\logs_bak06262019\Logs\Autosys\MY\DC\MAS_RYE_AX_DC_GETSOD_PROCESS_DAILY_2495598-1.out:770:SOD_AGBJ53399109_20190625_713865.xmltmp