Execute Package Utility: Set boolean property value

  • I have a boolean variable in my package called [User]::InitialLoad. The variable defaults to "False" but I want to be able to force it to "True" on the initial load, as the name suggests.

    I believe that, in the GUI version of the utility, in the Set Values tab, I should enter the property path like this:

    \Package.Variables[User::InitialLoad].Properties[Value]

    is that correct?

    Now, since InitialLoad is a Boolean variable, what should I put in the Value column to have the variable set to true or false, respectively:

    1. The literal string "True" or "False"?

    2. Numeric 1 or 0?

    3. Numeric -1 or 0? (I've seen -1 used in some old vb code)

    4. Something else?

  • I think I figured it out:

    for boolean variables, a numeric value of 0 is equivalent to False. Any other numeric value is equivalent to True. You can also pass in True or False, but any other text throws an error "could not set ... value to ..."

    Also, if you pass in the string "true" or "false", the case is irrelevant. I think I'll stick with a leading cap, to be consistent with the BIDS IDE

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply