Flyway Migrations to ER Diagram
Upload your migration folder or paste the scripts. We apply them in version order and show the schema they leave behind: tables, relationships and documentation.
Schema Visualizer
Visualize your database schemas with multiple diagram types
Upload several V*__*.sql files at once or paste them separated by a line such as “-- V2__add_orders.sql”. They are applied in version order.
Try a real schema
Click an example and we will load a set of migrations into the tool above, already separated by file.
Customers and orders
Five migrations: tables, a foreign key added later, ADD COLUMN, RENAME COLUMN and a repeatable view.
Blog
Authors, posts and comments, with a column dropped and another added in a later migration.
Key Features
See what your migrations build without spinning up a database
Multiple file upload
Select the whole migration folder at once. The files appear in the editor in the order they are applied, each one under a “-- V2__name.sql” line.
Real version order
Versions are compared number by number, as Flyway does: V1_10 goes after V1_9 and V2 after V1_10, regardless of how your file system sorts them.
Schema evolution applied
ADD and DROP COLUMN, RENAME COLUMN, RENAME TO, ADD CONSTRAINT … FOREIGN KEY, SET/DROP NOT NULL, type changes and DROP TABLE are applied one after another.
Repeatable migrations
R__ scripts (views, for example) run after the versioned ones, sorted by name. Undo migrations (U__) are not applied.
Notices instead of errors
An ALTER on a table that does not exist yet, a duplicated version or skipped statements are reported with the file name, without stopping the diagram.
No database needed
Migrations are read and applied in your browser. You do not need Flyway, Docker or a running database to see the schema.
How to Visualize Your Flyway Migrations
From the migration folder to an ER diagram in four steps
Find your migration folder
Usually src/main/resources/db/migration in Java projects
- ▸Versioned migrations: V1__init.sql, V1_1__add_users.sql…
- ▸Repeatable migrations: R__views.sql
- ▸Undo migrations (U__) are ignored
Upload or paste them
Select several files at once, or paste them with a separator line before each one
- ▸Separator line: -- V2__add_orders.sql
- ▸Without separators, the text is treated as a single migration
- ▸Simple Flyway placeholders (such as the schema name) are replaced so the SQL can be read
Check the order and the notices
Make sure the migrations were applied as you expect
- ▸The applied migrations are listed in order
- ▸Notices show the file and line of each problem
- ▸Edit the SQL in the editor and the diagram updates
Explore and export
Use the view that fits and share the result
- ▸ER Diagram to review a pull request with new migrations
- ▸Documentation as PDF for onboarding
- ▸Image for wikis and tickets
Frequently Asked Questions
About visualizing Flyway migrations