SQLines tools can help you transfer data, convert database schema (DDL), views, stored procedures, functions, triggers, queries and SQL scripts from MySQL to SingleStore.
Databases:
Converting literals:
| MySQL | SingleStore | ||||
| 1 | -- comment | # comment | Single-line comment | -- comment | # comment |
| 2 | _utf8'string' | _utf8mb4'string' | UTF-8 string literal | _utf8'string' | |
Converting character data types:
| MySQL | Singlestore | |||
| 1 | VARCHAR(n) | Variable-length string, 0 <= n <= 65535 | VARCHAR(n) | 0 <= n <= 21845 |
Converting numeric data types:
| MySQL | Singlestore | |||
| 1 | MEDIUMINT [UNSIGNED] | 24-bit integer | MEDIUMINT [UNSIGNED] | |
| 2 | SMALLINT [UNSIGNED] | 16-bit integer | SMALLINT [UNSIGNED] | |
| 3 | TINYINT [UNSIGNED] | 8-bit integer | TINYINT [UNSIGNED] | |
Converting datetime data types:
Other data types:
| MySQL | Singlestore | |||
| 1 | ENUM(value, value2, …) | Enumeration (one of values from the list) | ENUM(value, value2, …) | |
| 2 | SET(value, value2, …) | Set (one or more values from the list) | SET(value, value2, …) | |
Converting table definitions:
Converting stored procedures:
| MySQL | SingleStore | ||
| 1 | CREATE PROCEDURE [IF NOT EXISTS] name | CREATE OR REPLACE PROCEDURE name | |
| 2 | IN | OUT | INOUT param datatype(len) | Parameter definition | param datatype(len) |
| 3 | LANGUAGE SQL | Removed | |
| 4 | [NOT] DETERMINISTIC | Removed | |
| 5 | READS SQL DATA | Removed | |
| 6 | SQL SECURITY DEFINER | Removed | |
| 7 | COMMENT 'text' | Commented | |
For more information, see Converting Procedural (SPL) Statements.
Converting user-defined functions (UDF):
| MySQL | SingleStore | ||
| 1 | CREATE FUNCTION [IF NOT EXISTS] name | CREATE OR REPLACE FUNCTION name | |
| 2 | param datatype(len) | Parameter definition | param datatype(len) |
| 3 | LANGUAGE SQL | Removed | |
| 4 | [NOT] DETERMINISTIC | Removed | |
| 5 | READS SQL DATA | Removed | |
| 6 | SQL SECURITY DEFINER | Removed | |
| 7 | COMMENT 'text' | Commented | |
For more information, see Converting Procedural (SPL) Statements.
Converting MySQL procedural language (SPL).
Variable declarations:
| MySQL | SingleStore | ||
| 1 | DECLARE var type | Standalone DECLARE statements | DECLARE section before BEGIN … END block |
Converting SQL statements:
| MySQL | SingleStore | ||
| 1 | CREATE SCHEMA name … | Create schema | CREATE SCHEMA name … |
| 2 | DROP SCHEMA IF EXISTS name … | Drop schema | DROP SCHEMA IF EXISTS name … |
| 3 | USE name … | Set the default schema | USE name … |