开发者

SSIS set variable at runtime

Anyone know how I can change开发者_StackOverflow社区 a SSIS variable at runtime?

I have a variable User:SkipStuff

I want to set this based on a condition during a for loop container


Use Expression Task instead. In the "Expressions" pane, put the variable to set on left, then equates it to the intended value.

@[User::VariableToSet] = some expressions...

SSIS set variable at runtime


You can add a Script task. Add your SSIS variable(s) to the ReadWriteVariables property in the Script Task Editor.

You can reference the variable(s) in your script using the following format: Dts.Variables["MyCaseSensitiveVariableName"].Value


Lots of ways really, but the one I use most frequently is to use an execute SQL task and set the result set to single row and then put the results set into the variable.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜