From b578e6ce8926db116640ed459281f3ab72cd7812 Mon Sep 17 00:00:00 2001 From: Yuan <45984206+Yuan325@users.noreply.github.com> Date: Mon, 3 Feb 2025 10:34:01 -0800 Subject: [PATCH] docs(mssql): add docs for source (#256) Add docs for `mssql` source, and update for `mssql-sql` tool. --- docs/en/resources/sources/mssql.md | 49 ++++++++++++++++++++++++++++++ docs/tools/mssql-sql.md | 5 +-- 2 files changed, 52 insertions(+), 2 deletions(-) create mode 100644 docs/en/resources/sources/mssql.md diff --git a/docs/en/resources/sources/mssql.md b/docs/en/resources/sources/mssql.md new file mode 100644 index 0000000000..27ad92bbd3 --- /dev/null +++ b/docs/en/resources/sources/mssql.md @@ -0,0 +1,49 @@ +--- +title: "SQL Server" +type: docs +weight: 1 +description: > + SQL Server is a relational database management system (RDBMS). + +--- + +## About + +[SQL Server][mssql-docs] is a relational database management system (RDBMS) +developed by Microsoft that allows users to store, retrieve, and manage large +amount of data through a structured format. + +[mssql-docs]: https://www.microsoft.com/en-us/sql-server + +## Requirements + +### Database User + +This source only uses standard authentication. You will need to [create a +SQL Server user][mssql-users] to login to the database with. + +[mssql-users]: https://learn.microsoft.com/en-us/sql/relational-databases/security/authentication-access/create-a-database-user?view=sql-server-ver16 + +## Example + +```yaml +sources: + my-mssql-source: + kind: "mssql" + host: "127.0.0.1" + port: "1433" + database: "my_db" + user: "my-user" + password: "my-password" +``` + +## Reference + +| **field** | **type** | **required** | **description** | +|-----------|:--------:|:------------:|------------------------------------------------------------------------| +| kind | string | true | Must be "mssql". | +| host | string | true | IP address to connect to (e.g. "127.0.0.1"). | +| port | string | true | Port to connect to (e.g. "1433"). | +| database | string | true | Name of the SQL Server database to connect to (e.g. "my_db"). | +| user | string | true | Name of the SQL Server user to connect as (e.g. "my-user"). | +| password | string | true | Password of the SQL Server user (e.g. "my-password"). | diff --git a/docs/tools/mssql-sql.md b/docs/tools/mssql-sql.md index 7c8f2ad5b6..0e111386b8 100644 --- a/docs/tools/mssql-sql.md +++ b/docs/tools/mssql-sql.md @@ -1,9 +1,10 @@ -# Cloud SQL Mssql Tool +# SQL Server Tool -A "mssql-sql" tool executes a pre-defined SQL statement against a Cloud SQL for SQL Server +A "mssql-sql" tool executes a pre-defined SQL statement against a SQL Server database. It's compatible with any of the following sources: - [cloud-sql-mssql](../sources/cloud-sql-mssql.md) +- [mssql](../sources/mssql.md) Toolbox supports the [prepare statement syntax][prepare-statement] of MS SQL Server and expects parameters in the SQL query to be in the form of either @Name