Skip to content

SQL Server

SQL Server (a.k.a. MSSQL) is a Free-tier engine in Quay. Connection, schema browser, edit-as-draft, native dump, schema diff. The stored-proc trace mode (Pro Plus) is more developed here than on PG/MySQL because T-SQL exposes per-statement timing through the messages channel, which Quay surfaces inline.

FieldNotes
Hostlocalhost\SQLEXPRESS, mssql.example.com, …
Port1433 (default)
User · PasswordSQL auth (Windows auth not yet supported — use SQL auth or AD-Pass-through)
DatabaseInitial catalog
Encrypt / Trust server certtrue for Azure SQL, optional locally
SSH tunnelOptional

Azure SQL: pick Azure SQL as the dialect — same driver, the preset trims the catalog queries SQL Server doesn’t support on managed instances and adds the Encrypt=true; TrustServerCertificate=false defaults Azure requires.

  • FK-aware backup — walks sys.foreign_keys for ordering; snapshot via BEGIN TRANSACTION + READ COMMITTED SNAPSHOT.
  • Triggers, views, procedures, functions — preserved with SET ANSI_NULLS / QUOTED_IDENTIFIER headers so the dump parses on restore.
  • IDENTITY columnsIDENTITY_INSERT is toggled around the data load so existing seed values stay intact.
  • Default constraints — preserved with their generated DF__<table>__<col> names (so subsequent diffs don’t churn).
  • Stored-proc trace — right-click procedure → Trace. Opens the MssqlDebuggerDialog with three panels:

    • Statistics modes: TIME / IO / both / none
    • Optional PRINT '─── debug … ───' marker before the EXEC
    • Live messages output Internally Quay wraps the EXEC in SET STATISTICS TIME ON, etc., so per-statement duration + page-reads come back through the messages channel.
  • Query plansSET SHOWPLAN_XML ON or graphical plans through the EXPLAIN modal. Native plan parser surfaces the same rule-based interpretation as PG/MySQL (key lookups, missing index hints, lazy spool warnings).

  • Schema diff — works between two SQL Server connections or between SQL Server and any other engine.

  • SQL Server 2022+ requires TLS 1.2 by default. The driver picks this up automatically.
  • Self-signed certs on dev boxes: tick Trust server certificate on the connection. Quay surfaces the cert SHA-256 fingerprint on first connect (TOFU style) so a swap is visible.
  • Azure SQL: always require encryption. Quay’s Azure preset enforces this; manual override is possible but flagged.
  • Login failed for user — SQL auth user that exists in the master DB but not in the target DB. Run CREATE USER … FOR LOGIN … in the target DB.
  • Cannot open database "X" requested by the login — the login lacks CONNECT permission on the target. Quay surfaces the exact server error.
  • Invalid object name — schema-prefixing issue; Quay’s schema browser shows the schema explicitly so you can paste the fully-qualified name.
  • Windows authentication — SQL auth is the only path right now. Kerberos / SSPI ticket forwarding is on the roadmap; for now, set up an SQL-auth user.
  • Always Encrypted column-level keys — the wire-protocol driver supports it, but Quay’s grid hasn’t wired the per-column decryption hint yet. Encrypted columns show as <encrypted>.