Submitted byCategory
Review Cycle
.
Public
Joachim Mutter/sysarc
on 09/24/2009 at 11:31 PM
SSiS\Code

Skip Rows from a Pipeline during a Transform-ScriptTask

If you want to make a Scripttask filtering rows, means skip rows on defined properties, you have to use the OutputBuffer Property (from the synchronized Buffer) ExclusionGroup and set this to an non zeror value.
Doing so, only rows will tranfered to the output, if you explicit call Row.DirectRowToOutput(). This method is only available, if ExclusionGroup is set to a non zero value.

This may be suitable for Converters and Consisty Checks, where you must filter out rows with inconvertable values and rows which doesn't match consitity Rules.


Wrong rows must not be transported, so you could use the ExclusionGrouping Property and the explicit transport method "Row.DirectRowToOutput0()" to transport only valid rows.
All other rows stop here and the second output transports instead the error information!