SchemaSeed Guides

MySQL mock INSERT statements

MySQL and MariaDB reject some PostgreSQL habits. A reserved column name needs backticks, and a boolean column often wants 1 or 0 rather than true or false.

INSERT INTO `orders` (`id`, `order`, `paid`)
VALUES (1, 'a', 1);

SchemaSeed writes datetimes as YYYY-MM-DD HH:MM:SS, which MySQL accepts without a T. MariaDB uses the same export. TiDB and SingleStore are in the same family and are available with the free databases.

Generate MySQL inserts