Docs · Connecting to data
Microsoft SQL Server
SQL Server and Azure SQL Database — named instances, Windows authentication, and the TLS settings an older server needs.
Covers Microsoft SQL Server and Azure SQL Database. Both default to port 1433.
#Connection
| Field | Default | Notes |
|---|---|---|
| Server | — | Host, or HOST\INSTANCE for a named instance |
| Port | 1433 | "The static port. Set it, and it is used instead of the instance name." |
| Table | — | Optional — see SQL databases |
| Authentication | SQL Server login | Or Windows (NTLM) |
| Domain | — | Only shown for Windows authentication |
| Username | — | |
| Password | — | |
| Encrypt connection | On | |
| Trust server certificate | Off | Turn on for an instance with a self-signed certificate |
| Allow legacy TLS | Off | Only shown when Encrypt is on |
#Named instances
Two ways to reach one, and they interact.
Write HOST\INSTANCE in Server and leave the port blank, and the instance name is used to find the port through the SQL Browser service.
Set a Port and it wins — the instance name is no longer used to resolve anything. That is usually what you want on a server whose port is fixed, and it is more reliable than depending on the browser service being reachable.
#Allow legacy TLS
Accept TLS 1.0 and pre-2015 ciphers. Needed by SQL Server 2012 and older, which newer Node refuses to negotiate with.
If a connection to an older server fails during the handshake rather than at authentication, this is the setting. Leave it off everywhere else.
#Self-signed certificates
Trust server certificate is off by default, as it is for the other databases. With it on, the connection is encrypted but the server is never checked, so anything between Mosaic and the instance could pose as it and read the login.
Many internal SQL Server instances present a certificate they made themselves. When one does, the connection fails with a message that names this setting. Then either:
- install the certificate of the authority that issued it on the machine running Mosaic, which keeps the check, or
- turn Trust server certificate on for that system, if the network between them is one you trust.
Systems saved before this default changed keep the setting they were saved with.
#Running across many machines
Supported. See Running across many machines — each entry replaces the server, while port, database, credentials and query stay shared.