A comparison of ArcGIS, ArcSDE, and SQL Server data types
When you create a table or add a column to a table in the database, columns are created as a specific data type. Data types are classifications that identify possible values for and operations that can be done on the data, as well as the way the data in that column is stored in the database.
When you import data of one type into a column of another data type, you need to understand what the equivalent data types are between ArcSDE and your database management system (DBMS) because it can impact data content. Also, when creating new datasets in ArcGIS, it is helpful to know the equivalent data types between ArcGIS and your DBMS.
When you create a feature class or table in ArcGIS, there are 11 possible data types you can assign to a field. That means there are some data types that can only be created outside ArcGIS.
ArcSDE data type |
SQL Server data type |
ArcGIS data type |
Notes |
---|---|---|---|
SE_STRING_TYPE |
CHAR or VARCHAR |
TEXT |
Used for nonUnicode text, up to 8,000 characters |
SE_NSTRING_TYPE |
NCHAR or NVARCHAR |
TEXT |
Used for Unicode text, up to 4,000 characters |
SE_INT16_TYPE (SE_SMALLINT_TYPE) |
SMALLINT |
SHORT INTEGER |
|
SE_INT32_TYPE (SE_INTEGER_TYPE) |
INTEGER |
LONG INTEGER |
|
SE_INT64_TYPE |
BIGINT or NUMERIC (precision < 19, scale = 0) |
na |
The server configuration parameter INT64TYPES must be TRUE to create columns with this data type. |
SE_FLOAT32_TYPE (SE_FLOAT_TYPE) |
NUMERIC (precision < 7, scale > 0) |
na |
|
SE_FLOAT64_TYPE (SE_DOUBLE_TYPE) |
NUMERIC (precision > = 7, scale > 0) |
na |
|
SE_DATE_TYPE |
DATETIME |
DATE |
|
SE_UUID_TYPE |
UNIQUEIDENTIFIER |
GUID |
|
SE_BLOB_TYPE |
VARBINARY(MAX) |
BLOB |
|
SE_SHAPE_TYPE |
INTEGER, GEOMETRY, or GEOGRAPHY |
GEOMETRY |
SQL Server data type depends on the geometry storage specified for the layer. Compressed binary or well-known binary = NUMBER(38); Microsoft SQL Server Geometry = GEOMETRY; Microsoft SQL Server Geography = GEOGRAHY. |
SE_XML_TYPE |
SDE_XML or XML |
na |
XML columns are not exposed in ArcGIS Desktop. |
SE_RASTER_TYPE |
VARBINARY(MAX) or ST_RASTER |
RASTER |
SQL Server data type depends on the raster storage specified in the DBTUNE table. |
SE_STRING_TYPE |
INT(4) |
OBJECTID |
|
REAL |
FLOAT |
||
DOUBLE |
DOUBLE |
If scale is set to greater than 0 in ArcGIS, the SQL Server data type will be NUMERIC. |
|
SE_CLOB_TYPE |
VARCHAR(MAX) |
TEXT |
Used for nonUnicode text of 8,000 characters or more |
SE_NCLOB_TYPE | NVARCHAR(MAX) | TEXT | Used for Unicode text of 4,000 characters or more |