SSIS Accessing the properties of another Component from within a Script Component

  • Hi Guys,

    I have been trying to find out how to access the properties of one component from within a script task. Below is more exact scenario:

    I have a DataReaderSource that executes a query that is actually generated on the fly by an expression. I would like to be able to take that SQL Statement and read it using a script component that is within the same Data Flow.

    If I look at the Data Flow Task Properties it is stored as [GET Total Costs].[SqlCommand]

    So my question is do I reference this value from within my script component? I sure it something that can be done, I can't find any references to it.

    Any help would be very much appreciated!

    Thanks,

    Damien

  • Damien (1/21/2009)


    Hi Guys,

    I have been trying to find out how to access the properties of one component from within a script task. Below is more exact scenario:

    I have a DataReaderSource that executes a query that is actually generated on the fly by an expression. I would like to be able to take that SQL Statement and read it using a script component that is within the same Data Flow.

    If I look at the Data Flow Task Properties it is stored as [GET Total Costs].[SqlCommand]

    So my question is do I reference this value from within my script component? I sure it something that can be done, I can't find any references to it.

    Any help would be very much appreciated!

    Thanks,

    Damien

    Damien,

    You have to setup your [GET Total Costs].[SqlCommand] with "Expression". The expression should be based on package variable. You can then use this variable in your script component.

    ---
    SSIS Tasks Components Scripts Services | http://www.cozyroc.com/

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

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