IDTSOutput90.ExclusionGroup Property
Gets or sets the ExclusionGroup property of an IDTSOutput90 object.
네임스페이스: Microsoft.SqlServer.Dts.Pipeline.Wrapper
어셈블리: Microsoft.SqlServer.DTSPipelineWrap (in microsoft.sqlserver.dtspipelinewrap.dll)
구문
‘선언
<DispIdAttribute(101)> _
Property ExclusionGroup As Integer
[DispIdAttribute(101)]
int ExclusionGroup { get; set; }
[DispIdAttribute(101)]
property int ExclusionGroup {
int get ();
void set ([InAttribute] int plExclusionGroup);
}
/** @property */
/** @attribute DispIdAttribute(101) */
int get_ExclusionGroup ()
/** @property */
/** @attribute DispIdAttribute(101) */
void set_ExclusionGroup (/** @attribute InAttribute() */ int plExclusionGroup)
DispIdAttribute(101)
function get ExclusionGroup () : int
DispIdAttribute(101)
function set ExclusionGroup (plExclusionGroup : int)
속성 값
The ExclusionGroup of the IDTSOutput90 object.
주의
The ExclusionGroup property is set when two outputs are synchronous to the same IDTSInput90 object and you want to direct rows exclusively to one output or to the other. The SynchronousInputID property for each output must have the same value, and the ExclusionGroup property for each output must have the same value. You must set the ExclusionGroup property to a nonzero value if you want to use an exclusion group; otherwise, leave the default value of zero.
During execution, data flow components that have multiple outputs with the same synchronous input and the same nonzero exclusion group direct rows from the input PipelineBuffer to one of the outputs using the DirectRow method, or, when the IsErrorOut property is true, the DirectErrorRow method.
예
The following code example demonstrates how the ExclusionGroup property is used when a data flow component has two outputs in the same exclusion group and the same synchronous input.
public override void ProvideComponentProperties()
{
IDTSInput90 input = ComponentMetaData.InputCollection.New();
Input.Name = "DTSSampleInput";
IDTSOutput output = ComponentMetaData.OutputCollection.New();
output.ExclusionGroup = 1;
output.Name = "Output1";
output.SynchronousInputID = input.ID;
IDTSOutput output = ComponentMetaData.OutputCollection.New();
output.ExclusionGroup = 1;
output.Name = "Output2";
output.SynchronousInputID = input.ID;
}
public override void ProcessInput(int inputID, PipelineBuffer buffer)
{
IDTSInput90 input = ComponentMetaData.InputCollection.GetObjectByID(inputID);
IDTSOutput90 output1 = ComponentMetaData.OutputCollection[0];
IDTSOutput90 output2 = ComponentMetaData.OutputCollection[1];
if(! buffer.EndOfRowset)
{
while( buffer.NextRow())
{
// If criteria is met, direct the buffer row to output1.
buffer.DirectRow(output1.ID);
// Otherwise, direct the row to output2.
buffer.DirectRow(output2.ID);
}
}
}
Public Overrides Sub ProvideComponentProperties()
Dim input As IDTSInput90 = ComponentMetaData.InputCollection.New
Input.Name = "DTSSampleInput"
Dim output As IDTSOutput = ComponentMetaData.OutputCollection.New
output.ExclusionGroup = 1
output.Name = "Output1"
output.SynchronousInputID = input.ID
Dim output As IDTSOutput = ComponentMetaData.OutputCollection.New
output.ExclusionGroup = 1
output.Name = "Output2"
output.SynchronousInputID = input.ID
End Sub
Public Overrides Sub ProcessInput(ByVal inputID As Integer, ByVal buffer As PipelineBuffer)
Dim input As IDTSInput90 = ComponentMetaData.InputCollection.GetObjectByID(inputID)
Dim output1 As IDTSOutput90 = ComponentMetaData.OutputCollection(0)
Dim output2 As IDTSOutput90 = ComponentMetaData.OutputCollection(1)
If Not buffer.EndOfRowset Then
While buffer.NextRow
buffer.DirectRow(output1.ID)
buffer.DirectRow(output2.ID)
End While
End If
End Sub
스레드 보안
Any public static (Shared in Microsoft Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
플랫폼
개발 플랫폼
지원되는 플랫폼 목록은 SQL Server 2005 설치를 위한 하드웨어 및 소프트웨어 요구 사항을 참조하십시오.
대상 플랫폼
지원되는 플랫폼 목록은 SQL Server 2005 설치를 위한 하드웨어 및 소프트웨어 요구 사항을 참조하십시오.
참고 항목
참조
IDTSOutput90 Interface
IDTSOutput90 Members
Microsoft.SqlServer.Dts.Pipeline.Wrapper Namespace