Topic "if statement for filenames"

Author Message
xyz789
[View user's profile]

Joined: 2011-04-04
Posts: 1
I am currently pulling files from an ftp to use in an ssis package. At the moment I am using a wildcard to find the file as I know it will have a specific word in it. Unfortunately the company I am pulling these from also puts up test files with the same word in them and I am pulling test data. Is there a way to use an if like statement in order to determine if the word 'test' is in the filename and if so not download this file?
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
For complex solution, you would need to use XML logging:
http://winscp.net/eng/docs/guide_interpreting_xml_log

Simple solution would be to move all the files with the specific word to a different temporary remote folder, move the test files back, and download all remaining files in the temporary folder, moving them back to original folder if required.
_________________
Martin Prikryl
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License