[freetds] FreeTDS + ODBC

KC kcc1967 at gmail.com
Tue Jul 26 13:29:26 EDT 2005


Hi,

I have freetds-0.63 on Linux connect to MS SQL Server 2000.
I have all configure setup correctly and unittest for tds,dblib,ctlib
and odbc are ALL PASSed
(for ODBC, I use --with-odbc-nodm)

And now, I need a static only ODBC driver ... so I add an option
to configure, "--enable-shared=no".

Everything still working fine except that the ODBC now FAIL
with following error:

  odbctest
--------

connection parameters:
server:   'MyServer2k'
user:     'samples'
password: 'samples123'
database: 'tempdb'
Unable to open data source (ret=-1)
SQL error S1000 -- [FreeTDS][SQL Server]Unable to connect to data source


I didn't change anything !!!  It's work fine if shared library is enabed !!!
I don't have odbc.ini, just have freetds.conf at /usr/local/freetds/etc.

Do I really need odbc.ini.   All examples and doc I found show me that
in odbc.ini, I need a "Driver" which is a ".so" library ... but now I only use
static library and NO so in my build. 
Do I still need odbc.ini ?  How can I setup "Driver" in odbc.ini
if I don't have shared library ?


Thanks
KC



More information about the FreeTDS mailing list