Поделиться через


IDTSInput90.GetVirtualInput Method

Gets the IDTSVirtualInput90 object of an IDTSInput90 object.

Пространство имен: Microsoft.SqlServer.Dts.Pipeline.Wrapper
Сборка: Microsoft.SqlServer.DTSPipelineWrap (in microsoft.sqlserver.dtspipelinewrap.dll)

Синтаксис

'Декларация
<DispIdAttribute(105)> _
Function GetVirtualInput As IDTSVirtualInput90
[DispIdAttribute(105)] 
IDTSVirtualInput90 GetVirtualInput ()
[DispIdAttribute(105)] 
IDTSVirtualInput90^ GetVirtualInput ()
/** @attribute DispIdAttribute(105) */ 
IDTSVirtualInput90 GetVirtualInput ()
DispIdAttribute(105) 
function GetVirtualInput () : IDTSVirtualInput90

Возвращаемое значение

The IDTSVirtualInput90 object of the IDTSInput90.

Замечания

The GetVirtualInput method retrieves an IDTSVirtualInput90 object, which contains the collection of columns exposed in the IDTSOutput90 of the component connected to the IDTSInput90 through the IDTSPath90 object.

The IDTSVirtualInput90 object is not a persisted collection, and is simply a view of the IDTSOutput90 of the upstream component. Therefore, modifications to the IDTSVirtualInput90 or the columns contained in its VirtualInputColumnCollection are possible but do not have any impact on the IDTSOutput90 and its columns and thus should be avoided.

Columns from the VirtualInputColumnCollection are added and removed from the InputColumnCollection of the IDTSInput90 object by calling the SetUsageType method of the IDTSVirtualInput90 object.

If the IDTSInput90 object is not attached to an upstream component (its IsAttached property is false), the VirtualInputColumnCollection of the IDTSVirtualInput90 will be empty.

Пример

The following code example calls SetUsageType on each column in a virtual input.

private void MapAllColumns( IDTSInput90 input )
{
    IDTSVirtualInput90 vInput = input.GetVirtualInput();

    foreach( IDTSVirtualInputColumn90 vCol in vInput.VirtualInputColumnCollection )
    {
        vInput.SetUsageType( vCol.LineageID, DTSUsageType.UT_READWRITE);
    }
}
Private Sub MapAllColumns(ByVal input As IDTSInput90) 
 Dim vInput As IDTSVirtualInput90 = input.GetVirtualInput 
 For Each vCol As IDTSVirtualInputColumn90 In vInput.VirtualInputColumnCollection 
   vInput.SetUsageType(vCol.LineageID, DTSUsageType.UT_READWRITE) 
 Next 
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.

Платформы

Платформы разработки

Список поддерживаемых платформ см. в разделе Hardware and Software Requirements for Installing SQL Server 2005.

Целевые платформы

Список поддерживаемых платформ см. в разделе Hardware and Software Requirements for Installing SQL Server 2005.

См. также

Справочник

IDTSInput90 Interface
IDTSInput90 Members
Microsoft.SqlServer.Dts.Pipeline.Wrapper Namespace