I read a rant article the other day (I will update the link here as soon as I find it again) where the author was absolutely shooting down the use of the IN statement in queries, and proposing you rather use a JOIN and then compare fields in the WHERE clause.
Tag: SQL Server
SSIS – Accessing variables from script components
In SSIS there are are two different types of script components. The Control Flow script, and the Data Flow script. These 2 use different ways of accessing package variables, which was a bit confusing the first time I used teh Data Flow script component.
In the Control Flow script component you access package variables in a similar way to how DTS used to do it.
Dts.Variables("User::FromDate").Value.ToString
However, trying this in the DataFlow script component only cause some compilation errors and nothing more.
After doing some searching, I eventually found the simple solution that was staring me in the face all along, I just never tried it.
Me.ReadOnlyVariables("User::FileName").Value.ToString()
In both cases you still have to tell the component which variables you're passing in on the property page.
SQL Joins
Technical documentation being what it is, I've never found the explanation of joins in the SQL Books Online very clear, without actually going and playing with the dummy data and the different types of joins.
Now Jeff Atwood of Coding Horror fame has written the simplest explanation of join I've seen.