Delete last uploaded file
The script downloads the latest file with the ability to resume downloading to a remote server. Prompt a command which will delete a file in a local folder after its loading on the server. The script will be applied to a server whose local disk is full
@echo off "C:\Program Files (x86)\WinSCP\WinSCP.com" ^ /command ^ "open ftp://XXXXXXX:XXXXXXX@192.X.X.X/ -rawsettings AddressFamily=1" ^ "lcd D:\SQLBackup\archive" ^ "cd /BACKUP/W_C" ^ "put -latest *.bak -resume -neweronly -speed=0 -resumesupport=on"