recursive_acronym recursive_acronym - 1 year ago 108
Linux Question

FreeTDS - tsql connects, isql fails

I'm trying to connect to a database on my host machine (windows xp, sql server 05). My guest machine is Ubuntu 10.04. I can connect and execute commands with tsql, but isql fails. Below are my config files and error messages.


text size = 64512

host =
port = 1433
tds version = 7.0


Description = TDS driver (Sybase/MS SQL)
Driver = /usr/lib/odbc/
Setup = /usr/lib/odbc/
CPTimeout =
CPReuse =
FileUsage = 1


Driver = FreeTDS
Description = ODBC connection via FreeTDS
Trace = No
Servername =
Database = SCOPE_Peel
Port = 1433
UID = sa
PWD = test1234
ReadOnly = No


tsql -S SQLEXPRESS -U sa


isql SQLEXPRESS sa test1234 -v
[S1000][unixODBC][FreeTDS][SQL Server]Unable to connect to data source
[ISQL]ERROR: Could not SQLConnect

Answer Source

The issue was this line in odbc.ini

Servername =

It should have been SQLEXPRESS which I think points to the name of the server configured in freetds.conf

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download