MySQL syntax compatibility
This Intro compares the compatibility between ByteHouse MySQL and Native MySQL Database.
Start from Version 2.0.0.0, ByteHouse supports common Function and syntax of MySQL 5.7 and MySQL 8.0. This enables seamless integration with MySQL Client App and Tools. User can use the familiar MySQL Agreement to interact with ByteHouse and leverage the Function of the MySQL System.
Due to differences in Products architecture or limitations of customer requirements, some Function are Not supported. This section mainly discusses the differences between ByteHouse MySQL and Native MySQL Database in the following areas:
Pass the dialect_type Options, ByteHouse can Switch between MySQL Mode and ClickHouse Mode, for example:
SET dialect_type = 'CLICKHOUSE'; SET dialect_type = 'MySQL';
ByteHouse Default uses ClickHouse Mode.
Note
Recommended to use the above SET command to set dialect_type. It is not Recommended to set it at the Search level using SETTINGS, such as:
SELECT ... SETTINGS dialect_type = 'MySQL';
By implementation, many ANSI Function are controlled by individual sub-Options. dialect_type can be regarded as the Sum of these sub-Options. If needed, sub-Options can be used to control specific behaviour in MySQL Mode, for example:
SET dialect_type = 'MySQL';
Most MySQL behaviour is the same as ANSI and will not be Repeated here. Implicit conversion is introduced for Part of Function to align with MySQL behaviour.