Passing variable value from Script Component(data flow) to script task(control flow)

  • I am trying to pass a value from a script component to a script task.

    Basicall, how can I reference my global variables in a Data Flow task.

    This is what I trying to do:

    I am updating a database with data from a csv. It there is an error in the csv sent the failed row information to a "error table" But then I want to move orgianal .csv file to a a "failed" directory.

    So I thought I would set a ErrorFound variable to False and if a error occurs in the Data Flow set the variable to True. So the last step of the Control Flow reads if the varaible is True to move the file to the failed directory.

    Any other suggestions are more then welcome on how to handle this..

    Thanks,

    TeeKay

  • The solution was to assign the variable in the PostExcute as follows:

    Public Overrides Sub PostExecute()

    Me.Variables.ErrorFound = True

    MyBase.PostExecute()

    End Sub

    The global variable "ErrorFound" set in the packages variables.

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

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