Skip to content

MariaDB data types

MariaDB groups its column types into numeric, date and time, string, spatial and a few newer types such as UUID. Supported in the tables below means TableAI shows the value in the grid and lets you edit it where the column allows editing. The server checks each submitted value against the column definition.

Type What it stores TableAI
TINYINT 1-byte integer, -128 to 127 (0 to 255 unsigned) Supported
SMALLINT 2-byte integer, -32,768 to 32,767 (0 to 65,535 unsigned) Supported
MEDIUMINT 3-byte integer, -8,388,608 to 8,388,607 (0 to 16,777,215 unsigned) Supported
INT, INTEGER 4-byte integer, -2,147,483,648 to 2,147,483,647 (0 to 4,294,967,295 unsigned) Supported
BIGINT 8-byte integer, -2^63 to 2^63-1 (0 to 2^64-1 unsigned) Supported
DECIMAL, NUMERIC, DEC, FIXED Exact fixed-point number with a set precision and scale Supported
FLOAT Approximate single-precision number Supported
DOUBLE, REAL Approximate double-precision number Supported
BIT A bit-value of 1 to 64 bits Supported
BOOL, BOOLEAN Synonym for TINYINT(1) Supported
Type What it stores TableAI
DATE A calendar date Supported
TIME A time of day or an elapsed time, with optional fractional seconds Supported
DATETIME A date and time, with optional fractional seconds Supported
TIMESTAMP A date and time stored as UTC and converted to the session time zone, with optional fractional seconds Supported
YEAR A year Supported

What are the MariaDB string and binary types?

Section titled “What are the MariaDB string and binary types?”
Type What it stores TableAI
CHAR(n) Fixed-length text, padded to n characters Supported
VARCHAR(n) Variable-length text up to n characters Supported
TINYTEXT Text up to 255 bytes Supported
TEXT Text up to 65,535 bytes Supported
MEDIUMTEXT Text up to 16,777,215 bytes Supported
LONGTEXT Text up to 4,294,967,295 bytes Supported
BINARY(n), VARBINARY(n) Fixed-length and variable-length byte strings Supported
TINYBLOB, BLOB, MEDIUMBLOB, LONGBLOB Byte strings with the same size limits as the four text types Supported
ENUM One value from a list declared in the column Supported
SET Zero or more values from a list declared in the column Supported
JSON An alias for LONGTEXT with a check that the text is valid JSON Supported
UUID A 128-bit universally unique identifier Supported
INET6 An IPv6 address; also holds IPv4 addresses Supported
Type What it stores TableAI
GEOMETRY Any spatial value Supported
POINT, LINESTRING, POLYGON A single point, line or polygon Supported
MULTIPOINT, MULTILINESTRING, MULTIPOLYGON, GEOMETRYCOLLECTION A collection of spatial values Supported
Type Representation
Integer types Whole numbers, including values too large for a signed integer on the Mac
DECIMAL Exact decimal text, preserving its digits and scale
FLOAT, DOUBLE Text for the stored approximate number
DATE, DATETIME, TIMESTAMP, TIME Database date and time text, including fractional seconds
JSON JSON text, preserving whitespace and key order when edited
ENUM, SET The selected value or values as text
BIT A string of binary digits
BINARY, VARBINARY, BLOB A byte-size indicator with file actions
Spatial types Well-known text (WKT), with an SRID=<id>; prefix for a nonzero spatial reference ID

Preserve the database syntax when editing JSON, SET, or spatial text.

Open a binary cell’s menu and choose Save as… to retrieve its bytes into a file. For an editable cell, the same menu can stage a replacement from a local file. See read results for cell inspection and move data for export format controls.

Use the explicit Set to NULL or Set to DEFAULT actions for SQL values. Empty text is an empty string; typing NULL or DEFAULT into a text cell keeps it as text. The data editing guide covers staging, SQL preview, and applying changes.