未验证 提交 b8ae25c5 编写于 作者: A alexey-milovidov 提交者: GitHub

Merge pull request #14857 from vladimir-golovchenko/fix-connection-odbc-to-mssql-doc

Improved the description of connecting to MS SQL Server by ODBC.
...@@ -246,7 +246,7 @@ Installing unixODBC and the ODBC driver for PostgreSQL: ...@@ -246,7 +246,7 @@ Installing unixODBC and the ODBC driver for PostgreSQL:
$ sudo apt-get install -y unixodbc odbcinst odbc-postgresql $ sudo apt-get install -y unixodbc odbcinst odbc-postgresql
``` ```
Configuring `/etc/odbc.ini` (or `~/.odbc.ini`): Configuring `/etc/odbc.ini` (or `~/.odbc.ini` if you signed in under a user that runs ClickHouse):
``` text ``` text
[DEFAULT] [DEFAULT]
...@@ -321,7 +321,7 @@ You may need to edit `odbc.ini` to specify the full path to the library with the ...@@ -321,7 +321,7 @@ You may need to edit `odbc.ini` to specify the full path to the library with the
Ubuntu OS. Ubuntu OS.
Installing the driver: : Installing the ODBC driver for connecting to MS SQL:
``` bash ``` bash
$ sudo apt-get install tdsodbc freetds-bin sqsh $ sudo apt-get install tdsodbc freetds-bin sqsh
...@@ -329,7 +329,7 @@ $ sudo apt-get install tdsodbc freetds-bin sqsh ...@@ -329,7 +329,7 @@ $ sudo apt-get install tdsodbc freetds-bin sqsh
Configuring the driver: Configuring the driver:
``` bash ```bash
$ cat /etc/freetds/freetds.conf $ cat /etc/freetds/freetds.conf
... ...
...@@ -339,8 +339,11 @@ Configuring the driver: ...@@ -339,8 +339,11 @@ Configuring the driver:
tds version = 7.0 tds version = 7.0
client charset = UTF-8 client charset = UTF-8
# test TDS connection
$ sqsh -S MSSQL -D database -U user -P password
$ cat /etc/odbcinst.ini $ cat /etc/odbcinst.ini
...
[FreeTDS] [FreeTDS]
Description = FreeTDS Description = FreeTDS
...@@ -349,8 +352,8 @@ Configuring the driver: ...@@ -349,8 +352,8 @@ Configuring the driver:
FileUsage = 1 FileUsage = 1
UsageCount = 5 UsageCount = 5
$ cat ~/.odbc.ini $ cat /etc/odbc.ini
... # $ cat ~/.odbc.ini # if you signed in under a user that runs ClickHouse
[MSSQL] [MSSQL]
Description = FreeTDS Description = FreeTDS
...@@ -360,8 +363,15 @@ Configuring the driver: ...@@ -360,8 +363,15 @@ Configuring the driver:
UID = test UID = test
PWD = test PWD = test
Port = 1433 Port = 1433
# (optional) test ODBC connection (to use isql-tool install the [unixodbc](https://packages.debian.org/sid/unixodbc)-package)
$ isql -v MSSQL "user" "password"
``` ```
Remarks:
- to determine the earliest TDS version that is supported by a particular SQL Server version, refer to the product documentation or look at [MS-TDS Product Behavior](https://docs.microsoft.com/en-us/openspecs/windows_protocols/ms-tds/135d0ebe-5c4c-4a94-99bf-1811eccb9f4a)
Configuring the dictionary in ClickHouse: Configuring the dictionary in ClickHouse:
``` xml ``` xml
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册