Database Ingestion and Replication > Default data-type mappings > Microsoft SQL Server Source and Databricks Target
  

Microsoft SQL Server Source and Databricks Target

The following table identifies the recommended data-type mappings for Database Ingestion and Replication configurations with a Microsoft SQL Server source and a Databricks target:
Microsoft SQL Server Source Data Type
Databricks Target Data Type
bigint
bigint
binary(size), 1 <= size <= 8000
binary
bit
boolean
char(size), 1 <= size <= 8000
string
date
string
datetime
timestamp
datetime2(7)
string
datetime2(precision), 0 <= p <= 6
timestamp
datetimeoffset(7)
string
datetimeoffset(precision), 0 <= p <= 6
timestamp
decimal(p,s), 1 <= p <= 38, 0 <= s <= 38
decimal(p,s), 1 <= p <= 38, 0 <= s <= 38
float
double
geography
binary
geometry
binary
hierarchyid
binary
image
binary
int
integer
money
decimal(19,4)
nchar(size), 1 <= size <= 4000
string
ntext
string
numeric(p,s), 1 <= p <= 38, 0 <= s <= 38
decimal(p,s), 1 <= p <= 38, 0 <= s <= 38
nvarchar(size), 1 <= size <= 4000
string
real
float
smalldatetime
timestamp
smallint
integer
smallmoney
decimal(10,4)
sql_variant
binary
text
string
time(precision), 0 <= p <= 7
string
timestamp(8)
binary
tinyint
integer
uniqueidentifier
string
varbinary(size), 1 <= size <= 8000
binary
varchar(size), 1 <= size <= 8000
string
xml
string
LOB limitations
Database ingestion and replication jobs that use any of the load types can replicate data from SQL Server GEOGRAPHY, GEOMETRY, IMAGE, NTEXT, NVARCHAR(MAX), TEXT, VARBINARY(MAX), VARCHAR(MAX), and XML columns to Databricks targets. LOB data might be truncated before being written to the target. The truncation point depends on the data type and load type. For initial load jobs with a Databricks target, the truncation point for all SQL Server LOB data types is 16777216 bytes. For incremental loads and combined loads, if LOB columns contain more than 8 KB of data, the data is truncated to 4000 bytes if stored inline or to approximately 8000 bytes if stored out-of-line. For more information, see the "Include LOBs" description in Configure a Microsoft SQL Server source.
Unsupported source data types
DECIMAL or NUMERIC types with a scale greater than the precision are not supported.