Convert PostgreSQL schemas to MySQL DDL
See executable MySQL DDL generated from a PostgreSQL-shaped schema, with type changes and unsupported indexes reported rather than hidden.
- target
- MySQL DDL
- access
- Free export
- source specimen
- 2 of 13 tables · seed/schema.json
Trellis exports a schema drafted on its canvas using PostgreSQL types. This page does not claim to parse a PostgreSQL dump or a live database.
Review the type changes beside the DDL
The role table proves reserved-word quoting; the tag table proves keyed text and PostgreSQL extension types are handled deliberately.
| uuid | char(36) |
|---|---|
| timestamptz | datetime(6) |
| text in a key | varchar(255) |
| ltree | json |
create table role (
`key` varchar(255) not null,
name text not null,
description text,
primary key (`key`)
);
create table tag (
id char(36) not null default (uuid()),
label varchar(255) not null,
path json not null,
created_at datetime(6) not null default current_timestamp(6),
primary key (id),
unique (label)
);Runnable SQL still has dialect costs
These rules come from the MySQL dialect implementation that was exercised against the database, not from generic migration advice.
MySQL cannot index unbounded text, and Trellis cannot create a useful index on an unspecified JSON path. Keyed text is bounded to varchar(255); incompatible JSON indexes are omitted and reported.
source / src/lib/exporters/dialects.ts