다음을 통해 공유


DataTypeInfo.TypeEnumName Property

Returns the symbolic name of the data type. This field is read-only.

네임스페이스: Microsoft.SqlServer.Dts.Runtime
어셈블리: Microsoft.SqlServer.ManagedDTS (in microsoft.sqlserver.manageddts.dll)

구문

‘선언
Public ReadOnly Property TypeEnumName As String
public string TypeEnumName { get; }
public:
property String^ TypeEnumName {
    String^ get ();
}
/** @property */
public String get_TypeEnumName ()
public function get TypeEnumName () : String

속성 값

A string that contains the symbolic name of the data type.

주의

This returns the short name for the data type. For example, this property returns DT_R4 for a float.

The following code example iterates through the collection and prints the TypeEnumName and TypeName of each data type in SQL Server Integration Services (SSIS).

using System;
using System.Collections.Generic;
using System.Text;
using Microsoft.SqlServer.Dts.Runtime;

namespace DataTypeInfo_Properties
{
    class Program
    {
        static void Main(string[] args)
        {
            //Create the DataTypeInfos collection.
            DataTypeInfos dataInfos = new Application().DataTypeInfos;

            //Iterate over the collection, printing the values
            //of the properties.
            foreach (DataTypeInfo dInfo in dataInfos)
            {
                Console.WriteLine("TypeName: {0}, TypeEnumName: {1}", dInfo.TypeName, dInfo.TypeEnumName);
                //Console.WriteLine("TypeEnumName   {0}", dInfo.TypeEnumName);
            }
        }
    }
}
Imports System
Imports System.Collections.Generic
Imports System.Text
Imports Microsoft.SqlServer.Dts.Runtime
 
Namespace DataTypeInfo_Properties
    Class Program
        Shared Sub Main(ByVal args() As String)
            'Create the DataTypeInfos collection.
            Dim dataInfos As DataTypeInfos =  New Application().DataTypeInfos 
 
            'Iterate over the collection, printing the values
            'of the properties.
            Dim dInfo As DataTypeInfo
            For Each dInfo In dataInfos
                Console.WriteLine("TypeName: {0}, TypeEnumName: {1}", dInfo.TypeName, dInfo.TypeEnumName)
                'Console.WriteLine("TypeEnumName   {0}", dInfo.TypeEnumName);
            Next
        End Sub
    End Class
End Namespace

Sample Output:

TypeName: float, TypeEnumName: DT_R4

TypeName: double-precision float, TypeEnumName: DT_R8

TypeName: currency, TypeEnumName: DT_CY

TypeName: date, TypeEnumName: DT_DATE

TypeName: Boolean, TypeEnumName: DT_BOOL

TypeName: decimal, TypeEnumName: DT_DECIMAL

TypeName: single-byte signed integer, TypeEnumName: DT_I1

TypeName: single-byte unsigned integer, TypeEnumName: DT_UI1

TypeName: two-byte signed integer, TypeEnumName: DT_I2

TypeName: two-byte unsigned integer, TypeEnumName: DT_UI2

TypeName: four-byte signed integer, TypeEnumName: DT_I4

TypeName: four-byte unsigned integer, TypeEnumName: DT_UI4

TypeName: eight-byte signed integer, TypeEnumName: DT_I8

TypeName: eight-byte unsigned integer, TypeEnumName: DT_UI8

TypeName: file timestamp, TypeEnumName: DT_FILETIME

TypeName: unique identifier, TypeEnumName: DT_GUID

TypeName: byte stream, TypeEnumName: DT_BYTES

TypeName: string, TypeEnumName: DT_STR

TypeName: Unicode string, TypeEnumName: DT_WSTR

TypeName: numeric, TypeEnumName: DT_NUMERIC

TypeName: database date, TypeEnumName: DT_DBDATE

TypeName: database time, TypeEnumName: DT_DBTIME

TypeName: database timestamp, TypeEnumName: DT_DBTIMESTAMP

TypeName: image, TypeEnumName: DT_IMAGE

TypeName: text stream, TypeEnumName: DT_TEXT

TypeName: Unicode text stream, TypeEnumName: DT_NTEXT

스레드 보안

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 설치를 위한 하드웨어 및 소프트웨어 요구 사항을 참조하십시오.

참고 항목

참조

DataTypeInfo Class
DataTypeInfo Members
Microsoft.SqlServer.Dts.Runtime Namespace