SSIS Expressions

  • clucasi

    SSCrazy

    Points: 2113

    Hi All,

    Just wondered if someone could help, I have an SSIS package with two variables DateVal, and WeekNum.

    With dateval it needs to add 7 days to the variable every week when the package is ran and so on and  WeekNum needs to add 1 to the previous value up to 4 then reset back to 1 and so on.ssis

    If anybody could help it would be much appreciated, I have been trying to do it for a day and half up to now.

     

     

  • Phil Parkin

    SSC Guru

    Points: 243845

    When packages run, they cannot update themselves, so a wholly package-based solution is not the way ahead.

    However, your package can read from and write to a metadata table inside a database. Perhaps this gets you what you want?

    Even better (as it's self-contained and infinitely re-runnable) would be to derive your variables from run date. If you are able to do this and can provide the logic, we can help you implement it.

    If the answer to your question can be found with a brief Google search, please perform the search yourself, rather than expecting one of the SSC members to do it for you.

  • karen.ferrara

    Say Hey Kid

    Points: 701

    You might want to use a script to update your variable values rather than use an expression since you are updating every time the package is run.

  • Phil Parkin

    SSC Guru

    Points: 243845

    karen.ferrara wrote:

    You might want to use a script to update your variable values rather than use an expression since you are updating every time the package is run.

    If the logic is not too complex, an Expression task may be sufficient. We really need to understand the logic before deciding on the best implementation method, I think.

    If the answer to your question can be found with a brief Google search, please perform the search yourself, rather than expecting one of the SSC members to do it for you.

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

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