MySQL Compatibility

MatrixOne SQL syntax conforms with MySQL 8.0.23 version.

SQL TypeSQL SyntaxCompability with MySQL8.0.23
DDLCREATE DATABASEA database with Chinese name is not supported.
Names with Latins support limitedly.
CHARSET, COLLATE, ENCRYPTION can be used but don’t work.
CREATE TABLETemporary tables are not supported.
Partition tables are not supported.
Create table .. as clause is not supported now.
All column level constraints are not supported now.
Composite Primary Key is not supported yet.
KEY(column) is not supported yet.
AUTO_INCREMENT is not supported yet.
CREATE other projectsCREATE/DROP INDEX is not supported.
ALTERNot supported now.
DROP DATABASESame as MySQL.
DROP TABLESame as MySQL.
DMLINSERTLOW_PRIORITY, DELAYED, HIGH_PRIORITY are not supported now.
INSERT INTO VALUES with function or expression is not supported now.
Batch Insert can be supported up to 160,000 rows.
ON DUPLICATE KEY UPDATE is not supported now.
DELAYED is not supported now.
Names with Latins support limitedly.
The current SQL mode is just like only_full_group_by mode in MySQL.
SELECTTable alias is not supported in GROUP BY.
Distinct is limitedly support.
SELECT…FOR UPDATE clause is not supported now.
INTO OUTFILE is limitedly support.
LOAD DATAOnly csv files can be loaded currently.
The enclosed character should be “”.
FIELDS TERMINATED BY should be “,” or “
LINES TERMINATED BY should be “\n”.
SET is not supported now.
Local key word is not supported now.
Relative path is limited supported now. Only based on mo-server file can be supported.
JOINSame as MySQL.
SUBQUERYNon-scalar subquery is not supported now.
Database Administration StatementsSHOWOnly show tables and show databases are supported.
Show CREATE TABLE and CREATE DATABASE are supported.
Other statementsNot supported now.
Utility StatementsUSEUse database is the same as MySQL.
ExplainThe result of explain a SQL is different with MySQL.
Explain Analyze is not supported yet.
Other statementsNot supported now.
Data TypesBooleanDifferent from MySQL’s boolean which is the same as int , MatrixOne’s boolean is a new type, its value can only be true or false.
Int/Bigint/Smallint/TinyintSame as MySQL.
char/varcharSame as MySQL.
Float/doubleThe precision is a bit different with MySQL.
DECIMALThe max precision is 38 digits.
DateOnly ‘YYYY-MM-DD’ and ‘YYYYMMDD’ formats are supported.
DatetimeOnly ‘YYYY-MM-DD HH:MM:SS’ and ‘YYYYMMDD HH:MM:SS’ formats are supported.
TimestampSame as MySQL, but MatrixOne doesn’t support timezone yet, timestamp value doesn’t shift by timezone change.
Other typesNot supported now.
Operators“+”,”-“,”*”,”/“Same as MySQL.
DIV, %, MODSame as MySQL.
LIKESame as MySQL
INSupported for constant lists
NOT, AND, &&,OR, “||”Same as MySQL.
XORNot supported now.
CASTSupported with different conversion rules.
FunctionsMAX, MIN, COUNT, AVG, SUMSame as MySQL. Distinct is not supported yet.
any_valueAny_value is an aggregate function in MatrixOne. Cannot be used in group by or filter condition.