The following table lists mapping of data types for MaxCompute, Hive, Oracle, and MySQL.
MaxCompute data type Hive data type Oracle data type MySQL data type
BOOLEAN BOOLEAN None

CHAR(1), INTEGER, or NUMBER(1) is used instead. Value 1 indicates true and 0 indicates false.

None

TINYINT(1) is used instead.

TINYINT TINYINT NUMBER(3,0) TINYINT
SMALLINT SMALLINT NUMBER(5,0) SMALLINT
INT INT NUMBER(7,0) MEDIUMINT
INT INT NUMBER(10,0) INT
BIGINT BIGINT NUMBER(20,0) BIGINT
FLOAT FLOAT BINARY_FLOAT
Note This type is available in Oracle Database 10g or later.
FLOAT
DOUBLE DOUBLE BINARY_DOUBLE
Note This type is available in Oracle Database 10g or later.
DOUBLE
DECIMAL DECIMAL NUMBER(P,S)
  • DECIMAL
  • NUMERIC
STRING STRING
  • VARCHAR
  • VARCHAR2
  • CHAR
  • NCHAR
  • NVARCHAR3
  • VARCHAR
  • CHAR
VARCHAR VARCHAR
  • VARCHAR
  • VARCHAR2
  • CHAR
  • NCHAR
  • NVARCHAR3
VARCHAR
STRING CHAR CHAR CHAR
BINARY BINARY RAW
  • BINARY
  • VARBINARY
TIMESTAMP TIMESTAMP TIMESTAMP(N) Not supported
DATETIME DATE DATE DATETIME
ARRAY ARRAY Not supported Not supported
MAP MAP<key,value> Not supported Not supported
STRUCT STRUCT Not supported Not supported
Not supported UNION Not supported Not supported