SSIS Ignoring Script Component

  • Hi All.

    I am at my wits end with this problem. I have a flat source file followed by a derived Column task which is then followed by a data transformation script component. In the component I have added 2 columns from the data source, these are Address1 and Address2. I have changed the usage type to ReadWrite. I have then added some vb.net code to look at the values of these fields in the buffer and alter their output values.

    The problem is this code is not even running, the whole script component gets passed over as if it is not there. I have added a breakpoint in the code and it never gets there either as it does not attempt to run the code.

    Please help. Has anybody else ever experienced this before?

    Thanks

    Tim

  • Hi.

    As an update, here is the code I am trying to run in the script component. I have made the inputs of Address1 and Address2 ReadWrite

    Public Overrides Sub Input0_ProcessInputRow(ByVal Row As Input0Buffer)

    If Row.Address2_IsNull = True Then

    If InStr(";", Row.Address1) > 0 Then

    Row.Address1 = Left(Row.Address1, InStr(";", Row.Address1) - 1)

    Row.Address2 = Right(Row.Address1, Len(Row.Address1) - InStr(";", Row.Address1))

    ElseIf InStr("-", Row.Address1) > 0 Then

    Row.Address1 = Left(Row.Address1, InStr("-", Row.Address1) - 1)

    Row.Address2 = Right(Row.Address1, Len(Row.Address1) - InStr("-", Row.Address1))

    End If

    End If

    End Sub

    Has anybody got any ideas why this not working, it's driving me mad. The code isn't even running. I set up a new project from scratch in case of corruption and it still won't work.

    Thanks

    Tim

  • Without knowing what you've already tried, here are some suggestions...

    Is there some kind of a condition defined on the Precedence Contraint?

    Also, have you tried replacing your transformation script component with a simple script task that pops up a message box to see if the bug is specific to your script component?

  • I have exactly the same issue as the OP. There are no precedence constraint issues or event handler issues. To replicate my issue:

    - I create a completely new project.

    - I add a script task and set the language to VB.

    - I add no code, simply change the result of the script to FAIL.

    So, to be clear, there is only one thing in my package, a script task which fails. Plain and simple. In Visual Studio, it fails. Deployed to one SQL Server instance (2008R2) it fails when run from SQL Agent. When deployed to another SQL Server (2014 AG), the job succeeds. And it succeeds because the script task is ignored. If I put an Execute SQL Task immediately after the script task with invalid SQL, the package will fail on that EST.

    It's not the package, it's the server.

    Does anyone have any idea how to get the server not to ignore the script tasks?

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

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