MS SQL Server
Configuration reference for the MS SQL Server destination: ODBC driver and TLS setup, SQL vs. Azure AD authentication, sink options, and troubleshooting.
Microsoft SQL Server is a relational database engine. Nilus writes into SQL Server tables for both batch and CDC pipelines through the ODBC-backed SQL path. The connector supports both standard SQL Authentication (username + password) and Azure AD token-based authentication.
Requirements
Connectivity and credentials must both be in place before the pipeline can run.
Connectivity
The Nilus runtime must reach the SQL Server endpoint on the configured port (default
1433).The runtime image must include a working ODBC driver. Nilus expects
ODBC Driver 18 for SQL Serverby default.For Azure SQL Database / Managed Instance, allowlist the runtime egress IP on the server-level firewall and confirm the database is online (paused serverless tiers reject connections).
Required parameters
host
Yes
-
SQL Server host name.
port
No
1433
SQL Server port.
database
Yes
-
Target database.
username
Conditional
-
SQL login for password authentication. Omit when using Azure AD token authentication.
password
Conditional
-
Password for password authentication. When using Azure AD, this carries the access token (the driver receives it via MSSQL_COPT_SS_ACCESS_TOKEN).
driver
No
ODBC Driver 18 for SQL Server
ODBC driver name. Must match a driver actually installed in the runtime image.
TrustServerCertificate
No
driver default
yes to skip TLS certificate validation. Required when the server uses a self-signed certificate (common in dev environments).
Authentication
Conditional
-
Set to ActiveDirectoryAccessToken for Azure AD token-based authentication.
Permissions
The configured login or AAD principal needs:
CONNECTon the target database.CREATE TABLEon the target schema if Nilus is expected to auto-create tables.INSERT,UPDATE,DELETE,SELECTon the target tables according to the configuredincremental_strategy.
URI format
For Azure AD token authentication:
Sink options
dest_table
Yes
Target table in <schema>.<table> form (typically dbo.<table>).
incremental_strategy
Yes
One of replace, append, or merge.
Sample Nilus configs
Each example below is self-contained and uses the current Nilus pipeline shape.
Batch ingestion
CDC ingestion
Behavior and capabilities
Compute model: Nilus connects through ODBC and submits parameterized SQL writes; the SQL Server engine executes the load.
Object model: standard SQL Server tables addressed as
<schema>.<table>. The default schema in most installations isdbo.Supported pipeline types:
batchandcdc.Authentication modes: SQL Authentication (default) and Azure AD token-based authentication. For Azure AD, the destination uses ODBC's
MSSQL_COPT_SS_ACCESS_TOKENconnection attribute and skips theUID/PWD/AUTHENTICATIONkeywords from the credentials block.TLS posture: Driver 18 enforces encrypted connections by default. Set
TrustServerCertificate=yesonly for development scenarios; in production, install the server certificate's issuing CA into the runtime's trust store and leaveTrustServerCertificateunset (orno).
Troubleshooting
IM002 Data source name not found and no default driver specified
The ODBC driver named in the URI is not installed in the runtime.
Install ODBC Driver 18 for SQL Server in the runtime image, or set driver= to a driver that is installed.
SSL Provider: error code 0xfff… / certificate-trust failure
Driver 18 enforces TLS but cannot validate the server certificate.
Add TrustServerCertificate=yes to the URI for dev, or install the issuing CA into the runtime trust store for production.
Login failed for user
Wrong credentials, expired AAD token, or the user lacks CONNECT on the database.
Re-check credentials; for AAD, refresh the token; grant CONNECT if missing.
Cannot find the object … because it does not exist or you do not have permission
dest_table is missing the schema prefix and the user's default schema is not dbo.
Use the explicit <schema>.<table> form (typically dbo.<table>).
Token authentication unexpectedly silently fails
Authentication=ActiveDirectoryAccessToken was not set, so the driver tried UID/PWD against an empty username.
Add Authentication=ActiveDirectoryAccessToken to the URI query and pass the token as the URI password.
Related docs
MS SQL Server: companion batch source connector.
MS SQL Server: companion CDC source connector.
Optimize sink datasets: guidance on
incremental_strategyand dataset-shape tuning.
Last updated
Was this helpful?