Forum OpenACS Q&A: Re: ODBC-connection to Postgres database

Collapse
Posted by Jerry Asher on
using strace on isql, I can see that "something" looks for odbcinst.ini in /etc/pgsql, but I am wrong to think it is looking for odbc.ini there.  Instead, I can see "something" (everyone!) opening up /etc/odbc.ini and ~/.odbc.ini. I swear they open these files more than twenty times each.  Huh?

Also of note: in my odbc.ini under driver I give the exact path of the driver itself.  The syntax is that you can specify  either the complete path as I do, or a driver name to be found in the odbcinst.ini file.  If I do the latter, I get a segv.

odbc.ini

[mydsn]
Driver=/usr/lib/libpsqlodbc.so
Database=mydb
Servename=localhost
Port=5432