[freetds] Connecting to MS SQL Database with unixODBC, freetds, and perl
faight at yahoo.com
Tue Nov 15 17:48:41 EST 2005
I am attempting to connect to an MSSQL Database with unixODBC, freetds, and perl. I can connect
with tsql and isql, but when I run the perl connectivity test I get the following error:
Unable to connect to server [unixODBC][Driver Manager] Data source name not found, and no default
driver specified (SQL-IM002) (DBD: db_login/SQL Connect err=-1)
I have corresponding entries in the freetds.conf, the odbc.ini, and the odbcinst.ini files.
I can connect with isql and return a recordset manually.
I am using the following perl command to connect
my $dbh = DBI->connect("dbi:ODBC:server=$servername", $username, $password, (PrintError => 0));
Yahoo! FareChase: Search multiple travel sites in one click.
More information about the FreeTDS