Hey there

I am currently writing a SSIS package for looping through some text based log files and import the data into a sql 2005 database.

I have a for loop container which loops through the files and stores the filename and path into a SSIS variable, that works fine. But some of the log files are still being written to by the application so I want to ignore these files. So an expression to say if the last 2 chars of the filename are equal to the current hour then ignore the file.... is what's needed.
I have tried to create an expression for this but I do not understand how to tell the for loop container to movenext.

Here is my expression so far:

Property = FileNameRetreval (this isn't code)

RIGHT(@[User::FileFullName],2) == DATEPART("Hh",GETDATE()) ?

I dont know what to put after the '?' to tell the for loop container to movenext, I tried movenext() but this resulted in a syntax error.

I have done this kind of thing in DTS many times but I cant work it out in SSIS.