How to change the destionation based on condition?

  • Hi,

    I have a scenario where i have an SSIS package which has to pick the destination table based on the input. For example, assume that the input parameter can be either 1, 2 or 3... If i choose 1, the records should be pushed into the table Table1. If 2, Table 2. If 3, then Table3.

    How can this be achieved in SSIS? :ermm:

    Thanks in advance for any help.

    Soorya

  • Forgive me if this sounds silly, but there is a "conditional split" operation in the data flow transformations. Have you tried that?

  • I think u have misunderstood my question. I do understand what u r trying to say, but i want to know if there's a way to change the destination table name / DB name of a OLEDB destination component based on some input param.

  • If the conditional split doesn't meet your nees (for example if there's a variable number of potential destinations) you could use a script task to set the properties of an existing connection to point to whatever you need it to point to

  • i was unaware that the connection string could be changed using th eSQL task script. Would it be possible for you to brief about how to do this?

  • Soorya (10/10/2008)


    i was unaware that the connection string could be changed using th eSQL task script. Would it be possible for you to brief about how to do this?

    Problem solved, used 'expressions' to solve the issue.

Viewing 6 posts - 1 through 5 (of 5 total)

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