From 2df6c66380262ca22fdc064f6189571a1a3fa54d Mon Sep 17 00:00:00 2001 From: dat-a-man <98139823+dat-a-man@users.noreply.github.com> Date: Sat, 23 Mar 2024 04:50:30 +0000 Subject: [PATCH] Added info to mssql destination, on how to use windows authentication --- docs/website/docs/dlt-ecosystem/destinations/mssql.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/website/docs/dlt-ecosystem/destinations/mssql.md b/docs/website/docs/dlt-ecosystem/destinations/mssql.md index c5c019725d..c0bf2bcebf 100644 --- a/docs/website/docs/dlt-ecosystem/destinations/mssql.md +++ b/docs/website/docs/dlt-ecosystem/destinations/mssql.md @@ -61,6 +61,13 @@ You can also pass a SQLAlchemy-like database connection: destination.mssql.credentials="mssql://loader:@loader.database.windows.net/dlt_data?connect_timeout=15" ``` +To connect to an `mssql` server using Windows authentication, include `trusted_connection=yes` in the connection string. This method is useful when SQL logins aren't available, and you use Windows credentials. + +```toml +destination.mssql.credentials="mssql://username:password@loader.database.windows.net/dlt_data?trusted_connection=yes" +``` +> The username and password must be filled out with the appropriate login credentials or left untouched. Leaving these empty is not recommended. + To pass credentials directly, you can use the `credentials` argument passed to `dlt.pipeline` or `pipeline.run` methods. ```py pipeline = dlt.pipeline(pipeline_name='chess', destination='postgres', dataset_name='chess_data', credentials="mssql://loader:@loader.database.windows.net/dlt_data?connect_timeout=15")