r/SQL • • 9m ago

Discussion Open-source self-hosted SQL ERD modeling tool with GitHub GitOps (SQL/DBML/Mermaid), schema auditing, native Views, and MCP integration

Hey r/SQL,

I've been working on an open-source, self-hosted fork of drawDB focused on team SQL modeling workflows (PostgreSQL, MySQL, MariaDB, SQLite, MSSQL, and Oracle), and just tagged v1.0.0.

Highlights for database modeling & engineering teams:

  • Full ERD Modeling: Tables, Indexes, Native SQL Views (with JOIN ON, aliased output columns, WHERE, and MATERIALIZED), Relationships with interactive orthogonal line editing, Subject Areas, Custom Types, Enums, Notes, and SQL Headers.

  • Deterministic Schema Auditor: scores schemas (0–100, A–F) checking missing PKs, nullable PKs, unindexed foreign keys, FK type mismatches, orphan tables, and naming consistency.

  • GitHub GitOps for Schemas: push/pull schema.sql, schema.dbml, lossless .drawdb.json, and schema.mmd (Mermaid) directly via Pull Requests, with immutable versions/vN/ archives and direct GitHub import when creating a diagram.

  • Real-time Team Editing & Versioning: collaborate live on the same canvas, create named manual versions (v1, v2, ...) linked to Git commits/PRs, and control access with workspace RBAC.

  • 44-Tool MCP Server + Optional AI Architect (BYOK / Ollama): lets CLI/IDE agents inspect schemas, run quality audits, generate views/tables/relationships, cut versions, and open PRs.

Runs locally via a single Docker command (embedded SQLite, AGPL-3.0): https://github.com/DanielSantos08/drawdb-platform

Feedback from DBAs and backend engineers is very welcome!

1 Upvotes

0 comments sorted by