Post a reply

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

Re: Issue with -latest switch

Yes, this is an expected behavior. To get two files, use two get commands, each with one of the masks.
dkratter14

Issue with -latest switch

WinSCP 5.9.3

I'm trying to download the latest files that match a mask.

"open sftp://user:pass@host:port" "get /path/to/abc_*.csv /path/to/xyz_*.csv d:\downloads\ -latest" "exit"


I want it to get the latest file that matches abc_*.csv AND ALSO get the latest file that matches xyz_*.csv. So it should download two different files.

However, the behavior seems to be that it gets the latest file that matches abc_*.csv OR xyz_*.csv. It downloads one file.

Is this the expected behavior? Is there some way to get it to download two files?