SSIS Debugging Script Component... is there a better way?

  • Per Microsoft: http://msdn2.microsoft.com/en-us/library/ms136033.aspx

    The Script component does not support the use of breakpoints. Therefore, you cannot step through your code and examine values as the package runs. You can monitor the execution of the Script component by using the following methods:

    Interrupt execution and display a modal message by using the MessageBox.Show method in the System.Windows.Forms namespace. (Remove this code after debugging is complete.)

    Is using "MessageBox.Show" the best way to go about this?

    Anyone have a better recommendation?

    TeeKay

  • Unfortunately, there aren't any good tools for this as far as I know. You can add an additional output to your script task and write out debugging information to that output, then send it to a table or text file.

    Tim Mitchell, Microsoft Data Platform MVP
    Data Warehouse and ETL Consultant
    TimMitchell.net | @Tim_Mitchell | Tyleris.com
    ETL Best Practices

  • To avoid problems when forgetting to remove the MessageBox.Show code after debugging is complete, you can write your own debug function which calls Message.Show after checking the variable System::InteractiveMode.

    Peter

  • You can enable output from your script components in the logging section. Make you explictly select the dataflow object in you logging tree. The script component logging option (which appears at the VEEEERRRRY bottom) is only visible when you select the dataflow object. If you execute the package without debugging, script output shows up in the DOS window. 😉 The thing that stinks is that I haven't found away to pause the DOS window if I see something interesting while execution. :w00t:

  • Try CTRL+S to pause the command window and CTRL+Q to let it "run" again.

  • teekay-101299 (2/29/2008)


    Per Microsoft: http://msdn2.microsoft.com/en-us/library/ms136033.aspx

    The Script component does not support the use of breakpoints. Therefore, you cannot step through your code and examine values as the package runs. You can monitor the execution of the Script component by using the following methods:

    Interrupt execution and display a modal message by using the MessageBox.Show method in the System.Windows.Forms namespace. (Remove this code after debugging is complete.)

    Is using "MessageBox.Show" the best way to go about this?

    Anyone have a better recommendation?

    TeeKay

    Here are some workarounds for debugging Script Components:

    http://microsoft-ssis.blogspot.com/2011/04/breakpoint-does-not-work-within-ssis.html

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

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