Fog Creek Software
Discussion Board

Get a range of file using FTP

Is it possible to get a range of file using FTP
lets say from file SEL27000 to SEL28000

is there a way to do something like

GET SEL27000..SEL28000

(I'm using Windows XP using the FTP command line)

Friday, June 20, 2003

There is sort of a way, using mget, as in:

mget SEL2*000

Brent P. Newhall
Friday, June 20, 2003

Just remember to use the PROMPT command before issuing the MGET, or the FTP client (if you're at the command line) will ask you "Do you want to download file foo2000?" for EVERY FILE IN THE SET. A real pain if you want 30-40 files.

-Chris, who's made this mistake too many times.

Chris Tavares
Friday, June 20, 2003

Thanks for telling about the 'prompt' command!

Friday, June 20, 2003


If you're not tied to the XP FTP client, I would suggest using the 'curl' utility.  My experience has been that Microsoft's FTP clients don't implement wildcards very well at all.

'curl' is a command-line utility which can be used to interface with all kinds of network protocols, not just FTP.

You can download a version from here:

Then, the following single command would accomplish what you needed:

curl -sO ftp://username:password@hostname/SEL[27000-28000]

Norbert Burger
Saturday, June 21, 2003

Another option is filezilla - you can get it on SourceForge. Free graphical FTP client for windows. Then to get all the files you just do a "Select all" and push the transfer button.

Chris Tavares
Sunday, June 22, 2003

*  Recent Topics

*  Fog Creek Home