Jaa


Data Type Mappings from OLE DB Data Types (SQL Server Compact Edition)

SQL Server 2005 Compact Edition converts OLE DB data types to native SQL Server Compact Edition data types.

Data Type Mappings

The following table shows the mapping of native data types in SQL Server Compact Edition to the standard OLE DB data types, including any related properties and limitations.

SQL Server Compact Edition data type OLE DB data type OLE DB properties SQL Server Compact Edition specifics

bigint

DBTYPE_I8

 

 

binary

DBTYPE_BYTES

DBPROP_COL_FIXEDLENGTH = VARIANT_TRUE

 

bit

DBTYPE_BOOL

 

 

datetime

DBTYPE_DBTIMESTAMP

 

Valid year range 1753-9999; valid second range 0-59

float

DBTYPE_R8

 

 

image

DBTYPE_BYTES

 

 

integer

DBTYPE_I4

 

 

money

DBTYPE_CY

 

 

national character

DBTYPE_WSTR

DBPROP_COL_FIXEDLENGTH = VARIANT_TRUE

 

national character varying

DBTYPE_WSTR

DBPROP_COL_FIXEDLENGTH = VARIANT_FALSE

 

ntext

DBTYPE_WSTR

 

 

numeric

DBTYPE_NUMERIC

 

 

real

DBTYPE_R4

 

 

smallint

DBTYPE_I2

 

 

uniqueidentifier

DBTYPE_GUID

 

 

tinyint

DBTYPE_UI1

 

 

varbinary

DBTYPE_BYTES

DBPROP_COL_FIXEDLENGTH = VARIANT_FALSE

 

See Also

Reference

OLE DB Provider Reference (SQL Server Compact Edition)

Concepts

Building Native Applications (SQL Server Compact Edition)

Help and Information

Getting SQL Server Compact Edition Assistance