I have an SSIS package where I am setting two variables in tasks the beginning (first image). Good to go.
Further down I have a data flow task with an expression (second image) to set a Lookup.SQLCommand property to concatenate a string value that uses those two variables.
Good to go BUT the problem I'm having is that the data flow task.lookup is grabbing the variables values that are in the SSIS package BEFORE the tasks are executed to set those variables.
Big hairy question
: How can I specifically state to get variables at runtime when a component is executed, and not before the package runs?
Possible workaround question
: What's the VB syntax in a script task to set a lookup.SQLCommand to a value?
The reason for doing this is I am pumping 40+ tables from SalesForce.com to SQL, and I'd like to avoid inserting duplicates. The package extracts from these tables only between these two dates. The lookup on the target will lock the entire table, so to avoid that I'd like to add a WHERE clause on these two dates.