Liquibase Changelog Generator
Paste the SQL DDL you already have and get a ready-to-commit Liquibase changelog. Columns, primary keys, NOT NULL and UNIQUE constraints, foreign keys, auto-increment columns, computed defaults and secondary indexes are all translated into createTable, addPrimaryKey and createIndex changes, each wrapped in its own changeSet with a generated rollback. Pick XML, YAML, JSON or Liquibase formatted SQL to match your project layout. Types are emitted in Liquibase's database-agnostic form so one changelog can target PostgreSQL, MySQL and Oracle. Parsing happens entirely in your browser.
Do more than liquibase changelog generator — meet Chat2DB
Chat2DB is an AI-powered SQL client for Windows, macOS and Linux. Write SQL in natural language, format and optimize queries automatically, and manage MySQL, PostgreSQL, Oracle and 20+ other databases in one workspace.
How to use
- Paste your CREATE TABLE and CREATE INDEX statements into the DDL box.
- Set the changeSet author and id prefix, then choose XML, YAML, JSON or formatted SQL output.
- Copy the changelog into your project (for example db/changelog/db.changelog-1.0.xml) and verify it with liquibase update-sql before running liquibase update.
Frequently asked questions
What is a Liquibase changelog?
A changelog is the ordered file that records every change Liquibase should apply to your database. It is a list of changeSets, each identified by an id and author pair. When you run liquibase update, Liquibase compares the changelog against the DATABASECHANGELOG table, applies only the changeSets that have not run yet, and stores a checksum so an already-applied changeSet is never executed twice.
Should I use XML, YAML, JSON or SQL for my changelog?
XML has the fullest tooling and XSD validation, and is the most common choice in Java projects. YAML and JSON express exactly the same changes with less ceremony and suit teams that already use those formats. Liquibase formatted SQL keeps raw dialect-specific SQL with --changeset comments, which is useful when you need database-specific syntax, but you give up the database-agnostic types and automatic rollback generation that the structured formats provide.
Can I edit a changeSet after it has been applied?
No. Liquibase stores a checksum of each applied changeSet, so editing one causes a validation failure on the next update. Add a new changeSet describing the follow-up change instead. If a checksum change is genuinely intentional, clear it with liquibase clear-checksums or set a runOnChange attribute — but for schema changes, appending a new changeSet is almost always the correct move. To inspect the resulting schema across environments, connect with Chat2DB at https://chat2db.ai/download or https://app.chat2db.ai.
