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


Конструктор DataType (SqlDataType, String)

Initializes a new instance of the DataType class based on a specified SQL Server data type with the specified type.

Пространство имен:  Microsoft.SqlServer.Management.Smo
Сборка:  Microsoft.SqlServer.Smo (в Microsoft.SqlServer.Smo.dll)

Синтаксис

'Декларация
Public Sub New ( _
    sqlDataType As SqlDataType, _
    type As String _
)
'Применение
Dim sqlDataType As SqlDataType 
Dim type As String 

Dim instance As New DataType(sqlDataType, _
    type)
public DataType(
    SqlDataType sqlDataType,
    string type
)
public:
DataType(
    SqlDataType sqlDataType, 
    String^ type
)
new : 
        sqlDataType:SqlDataType * 
        type:string -> DataType
public function DataType(
    sqlDataType : SqlDataType, 
    type : String
)

Параметры

Примеры

Visual Basic

'Declare and create a DataType object variable.
Dim dt As DataType
dt = New DataType(SqlDataType.

PowerShell

$dt = new-object Microsoft.SqlServer.Management.Smo.DataType([Microsoft.SqlServer.Management.Smo.SqlDataType]::

См. также

Справочник

DataType Класс

Перегрузка DataType

Пространство имен Microsoft.SqlServer.Management.Smo