Skip to Content.
Sympa Menu

freetds - [freetds] Unable to connect to Data Source using iodbctest

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "Lee, Gary" <GLee AT etrade.com>
  • To: <freetds AT lists.ibiblio.org>
  • Subject: [freetds] Unable to connect to Data Source using iodbctest
  • Date: Tue, 21 Sep 2004 18:08:54 -0400

> Problem in a nutshell: tslq works, iodbctest doesn't.
>
> I've configured FREETDS and iODBC on Solaris.
>
> The tsql program works, with this freetds.conf file:
>
> [Canada]
> host = 10.xx.xx.xxx (blocked out for privacy reasons)
> port = 1433
> tds version = 8
>
> Environment variables ODBCINI and FREETDS are defined in my environment,
> and point to the files in my
> home directory.
>
> BUT:
>
> Running iodbctest, results in the following error from FreeTDS:
>
> ./iodbctest "DSN=Canada;UID=gary;PWD=lucky"
> iODBC Demonstration program
> This program shows an interactive SQL processor
> Driver Manager: 03.51.0002.0224
> 1: [FreeTDS][SQL Server]Unable to connect to data source (0), SQLSTATE=08001
>
> Here's my odbc.ini file:
>
> ;
> ; odbc.ini
> ;
> [ODBC Data Sources]
> Canada = Foreign Symbol Database
>
> [Canada]
> Driver = /usr/local/freetds/lib/libtdsodbc.so
> Description = FREETDS / odbc test db
> Host = qa1
> Port = 1433
> ServerType = SQL Server 2000
> FetchBufferSize = 99
> UserName = gary
> Password = lucky
> Database = IMM2
> ServerOptions =
> ConnectOptions =
> Options =
> ReadOnly = no
>
> [Default]
> Driver = /usr/local/freetds/lib/libtdsodbc.so
>
>
> Questions:
>
> 1. Most imortantly: Why doesn't it connect using the iodbctest program? I
> assume it's an odbc.ini
> problem, since tsql works.
>
> 2. Where would I find descriptions of error codes, like SQLSTATE=8001 ?
>
> 3. Why are the UID/PWD command line arguments needed when Username and
> Password
> are in already the odbc.ini file?
>
> Any help would be greatly appreciated!
> Thanks, Gary




Archive powered by MHonArc 2.6.24.

Top of Page