Canner / wren-engine

🤖 The semantic engine for LLMs, bringing semantic context to AI agents. 🔥
https://getwren.ai/oss
Apache License 2.0
129 stars 34 forks source link

fix(mssql): update tds version #826

Closed grieve54706 closed 1 month ago

grieve54706 commented 1 month ago

We found an error.

('42000', '[42000] [FreeTDS][SQL Server]Unicode data in a Unicode-only collation or ntext data cannot be sent to clients using DB-Library (such as ISQL) or ODBC version 3.7 or earlier. (4004) (SQLFetch)')

The default TDS or ODBC version in the base image python:3.11-slim-buster(Debian 10) may be too low. The default TDS version is 4.2. Update the version, and it will be fine. You can execute tsql -C in the container will get this.

# tsql -C
Compile-time settings (established with the "configure" script)
                            Version: freetds v1.00.104
             freetds.conf directory: /etc/freetds
     MS db-lib source compatibility: no
        Sybase binary compatibility: yes
                      Thread safety: yes
                      iconv library: yes
                        TDS version: 4.2
                              iODBC: no
                           unixodbc: yes
              SSPI "trusted" logins: no
                           Kerberos: yes
                            OpenSSL: no
                             GnuTLS: yes
                               MARS: no

Reference: https://www.freetds.org/userguide/choosingtdsprotocol.htm https://learn.microsoft.com/en-us/sql/relational-databases/security/networking/tds-8