Avoiding 0 kb files using (get -delete)
Hello WinSCP scripting guru!
I am using a following script to get xml files from FTP server to a local folder on one of the servers on the perimeter network.
The script is working, getting file by file from FTP and deleting pulled file on FTP.
The files on FTP are pushed by a third party vendor with a real time schedule.
Sometimes i am getting 0 kb files from FTP because script starts the same time vendor pushed the file. Because script deleting file by file right after GET, i can't use a masking for the file size.
How to accomplish the same logic (get file by file with delete option on FTP) but avoid a 0 kb files?
Thank you so much,
You�re TOYO.
I am using a following script to get xml files from FTP server to a local folder on one of the servers on the perimeter network.
option batch on option confirm off open ftp://ftpname:password@xx.xxx.xxx.xxx cd EXAM\IN option transfer binary get -delete 1122result_*.xml \\servername\data\FTP\ close exit
The files on FTP are pushed by a third party vendor with a real time schedule.
Sometimes i am getting 0 kb files from FTP because script starts the same time vendor pushed the file. Because script deleting file by file right after GET, i can't use a masking for the file size.
How to accomplish the same logic (get file by file with delete option on FTP) but avoid a 0 kb files?
Thank you so much,
You�re TOYO.