Monthly Archives: August 2015 - Page 4

Ignore Few Files – For Each Loop Container (SSIS)

Imagine a situation where you are processing all files in a folder and few files need not be processed in SSIS.

Here are the steps:

  1. Configure for each loop container to iterate thru a folder and store each file name in a variable (say FileName)
  2. Use execute SQL task and then connect to the data flow task. Connect and use expression & constraint and use expression as follows

[cc lang=”SQL”]

findstring(@FileName, “2012-10-14”, 1) == 0

[/cc]

    3. Also use a file system task to move the processed file to Archive folder
    4. Even better if you can use checkpoint to start the package from the point of failure