Show HN: Xsql โ€“ Convert SQL Schemas Across MySQL, Postgres, and SQLite
github.comยท12hยท
Discuss: Hacker News
๐Ÿ’พDatabases
Preview
Report Post

xsql

Convert SQL schema DDL between dialects (currently focused on CREATE TABLE ...) via a small intermediate representation.

What it does (today)

  • Parses schema DDL from:

  • MySQL

  • PostgreSQL

  • SQLite

  • Emits schema DDL to:

  • MySQL

  • PostgreSQL

  • SQLite

  • Converts:

  • a single .sql file โ†’ another .sql file

  • a whole folder tree of .sql files โ†’ a destination folder (preserves relative paths)

  • Includes an interactive TUI (xsql tui).

Quickstart

Install and run quickly (recommended):

# one-line install (clones, builds, installs to $HOME/.cargo/bin)
curl -fsSL https://raw.githubusercontent.com/Dawaman43/xsql/main/install.sh | sh

# then run the tool
xsql --help

Build from source

If you prefer to build locally:

cargo build --release...

Similar Posts

Loading similar posts...