[freetds] isql works but tsql does not

Belegnar The Dragon admin at zilantkon.ru
Mon Apr 21 04:00:21 EDT 2014


I'm trying to make queries to mssql 2005 via freetds on ubuntu 12.04.
FreeTDS version 0.91-1
unixodbc version 2.3.0

There is a problem in here.
The problem is with query
select [Заказы].[Номер заказа] from [Заказы] where [Заказы].[Номер 
заказа] = '14-01-0001' # mssql's db uses cyrillic names in tables and 
columns =(
When i ran it in osql script everything works fine. But it does not work 
in tsql. In tsql i should write
use rt # database name is 'rt'
<the query mentioned above>
Than it works either.
Without 'use rt' i got error 'Invalid object name [Заказы]'

Could anybody help me, please?

Database name is mentioned in
$ cat ~/.odbc.ini
driver          = FreeTDS
servername      = RTTDS
port            = 1433
database        = rt
tds_version     = 7.0
client_charset  = UTF8

$ cat ~/.freetds.conf
     port = 1433
     tds version = 7.0
     dump file = /tmp/freetds.log
     debug flags = 0xffff

         host = rt-bd.rt-moscow.kiam.ru
         #host =
         port = 1433
         tds version = 7.0
         client charset = UTF8
         text size = 50000000


More information about the FreeTDS mailing list