Supported database

Microsoft SQL Server schema diagrams from migrations

Run your migrations on a real SQL Server 2017, 2019, 2022, 2025 in Docker and get the resulting schema as an SVG. 17 migration tools can draw on SQL Server.

Versions

Pass the version as the version field with databaseType=MSSQL. Each one is a stock image, started fresh for every drawing.

VersionImage
2017mcr.microsoft.com/mssql/server:2017-latest
2019mcr.microsoft.com/mssql/server:2019-latest
2022mcr.microsoft.com/mssql/server:2022-latest
2025mcr.microsoft.com/mssql/server:2025-latest

What the diagram shows on SQL Server

Tables land in dbo unless the migration says otherwise. SQL Server takes longer to start than the other engines, so the first seconds of a drawing are spent waiting for it.

The types are the names the engine's JDBC metadata reports, without lengths: an integer column reads int, a short text varchar, a calendar date date. Tables are read from dbo; the migration tool's own bookkeeping table is left out.

Migration tools that draw on SQL Server

Not offered on SQL Server

  • dbmate (no SQL Server driver in dbmate)
  • Atlas (SQL Server is not in the Atlas Community edition)
  • Drizzle ORM (Drizzle has no SQL Server migrator)
  • Sqitch (Sqitch has no SQL Server engine)
  • Diesel (Diesel has no SQL Server backend)
petclinic on sql server 2025
ER diagram of the PetClinic schema drawn by SchemaDrawer on Microsoft SQL Server 2025

The PetClinic sample, drawn from Flyway migrations on Microsoft SQL Server 2025. Open the SVG.

Run it

Draw on SQL Server 2025

The same request works for every tool; only migrationType and the files change.

curl -X POST https://schemadrawer.com/api/v1/drawing \
  -H "Request-Id: $(uuidgen)" \
  -F "userId=5f0c1d2e-3a4b-4c5d-8e6f-7a8b9c0d1e2f" \
  -F "migrationType=FLYWAY" \
  -F "databaseType=MSSQL" \
  -F "version=2025" \
  -F "files=@db/migration/V1__create_owners_and_pets.sql" \
  -F "files=@db/migration/V2__create_vets.sql" \
  -F "files=@db/migration/V3__create_visits.sql"
# {"jobId":"0b6e2f4c-8d1a-4c3e-9f7a-2a5b6c7d8e9f"}
- uses: schemadrawercom/action@v1
  with:
    sql-directory: db/migration
    output-path: docs/schema-diagram.svg
    migration-type: FLYWAY
    database-type: MSSQL
    database-version: '2025'
    github-token: ${{ secrets.GITHUB_TOKEN }}
From the blog

Reading about SQL Server

Draw your SQL Server schema now

Upload the migration directory, pick the version you deploy to, get an SVG back.