Help Center/ DataArts Fabric/ Developer Guide/ SQL Syntax Reference/ Data Types/ Mapping Between DataArts Fabric SQL and LakeFormation Data Types
Updated on 2025-09-18 GMT+08:00

Mapping Between DataArts Fabric SQL and LakeFormation Data Types

There is a clear mapping between the data types defined in DataArts Fabric SQL and those in LakeFormation, as shown in the table below.

Table 1 Mapping between DataArts Fabric SQL and LakeFormation data types

Data Type

DataArts Fabric SQL Data Type

Description

LakeFormation Data Type

Remarks

Numeric type

SMALLINT

Small integer, also called INT2.

smallint

-32,768 ~ +32,767

INTEGER

Typical choice for integer, also called INT4.

int

-2,147,483,648 ~ +2,147,483,647

BIGINT

Big integer, also called INT8.

bigint

-9,223,372,036,854,775,808 ~ 9,223,372,036,854,775,807

NUMERIC[(p[,s])],

DECIMAL[(p[,s])]

The value range of p (precision) is [1, 1000], and the value range of s (standard) is [0, p].

decimal

1≤p≤38, 0≤s≤p;

If p is unspecified, an error prompts exceeding the precision range.

REAL,FLOAT4

Single-precision floating-point number, imprecise.

float

6-digit decimal precision.

DOUBLE PRECISION, FLOAT8

Double-precision floating-point number, imprecise.

double

15-digit decimal precision.

FLOAT[(p)]

Floating-point number, imprecise. The value range of precision (p) is [1, 53].

If the precision is not specified, DOUBLE PRECISION is used by default.

float/double

If 1 ≤ p < 25, the data is stored as float. If 25 ≤ p ≤ 53, the data is stored as double.

DEC[(p[,s])]

The value range of p (precision) is [1, 1000], and the value range of s (standard) is [0, p].

decimal

1≤p≤38, 0≤s≤p;

If p is unspecified, an error prompts exceeding the precision range.

INTEGER[(p[,s])]

The value range of p (precision) is [1, 1000], and the value range of s (standard) is [0, p].

decimal

1≤p≤38, 0≤s≤p;

If p is unspecified, an error prompts exceeding the precision range.

Boolean type

BOOLEAN

Boolean: true, false, or null

boolean

-

Character type

CHAR(n),CHARACTER(n),NCHAR(n)

Fixed-length string. n indicates character length padded with spaces if insufficient, n ≤ 255.

char

1 ≤ n ≤ 255. If n is not specified, the default value 1 is used.

VARCHAR(n),CHARACTER VARYING(n)

Variable-length string. n indicates the character length. The value of n is less than or equal to 65535.

varchar

1 ≤ n ≤ 65535. If n is not specified, the default value 65535 is used.

TEXT

Variable-length string.

string

-

Date/Time type

DATE

Record date.

date

If the data includes time information, it is truncated to store only the date data.

TIMESTAMP[(p)] [WITHOUT TIME ZONE]

Date and time without time zone information.

p indicates precision after the decimal point. The value ranges from 0 to 6.

timestamp

The actual storage precision is fixed at 6 and is not affected by the value of p. If p is greater than 6, the precision is decreased to 6.

Binary type

BYTEA

Variable-length binary string.

binary

-