ODBC conection

stan stanb at panix.com
Thu Jul 1 18:53:09 UTC 2010


On Thu, Jul 01, 2010 at 01:47:12PM -0400, Mike McGinn wrote:
> 
> On Thursday 01 July 2010 13:33:22 stan wrote:
> > I have a peice of dedicated hardwarethatis suposed to provide remote ODBC
> > connectivity. It uses Postgres for it's database.
> > 
> > I have never done ODBC before. How do I go about setting up access to this
> > device? Do I need to use something like Open Office? It appears that both
> > base, and calc support ODBC conectivity, but it looks like this is one of
> > those "standards that are not a standard".
> > 
> > It appears that I need to define an ODBC instnace at teh OS level, before
> > OO can use it. is this correct? If so, how do I go about doing that?
> > 
> You have to install the postgres odbl lib (odbc-postgresql) and you have to 
> configure /etc/odbc.ini. I have not done it in ages but the man pages should 
> help.
> 

Thanks for the help. I have installed odbc-postgresql, but unfortunately
that does not seem to have put the correct enires in /etc/odbcinst.ini.
Here is what it looks like:

stan at plabws1:~$ cat /etc/odbcinst.ini
[SQLite]
Description             = SQLite ODBC Driver
Driver          = /usr/lib/odbc/libsqliteodbc.so
Setup           = /usr/lib/odbc/libsqliteodbc.so
UsageCount              = 1

[SQLite3]
Description             = SQLite3 ODBC Driver
Driver          = /usr/lib/odbc/libsqlite3odbc.so
Setup           = /usr/lib/odbc/libsqlite3odbc.so
UsageCount              = 2


I added the following by hand:

[postgress]
Description             = postgress ODBC Driver
Driver          = /usr/lib/odbc/psqlodbca.so
Setup           = /usr/lib/odbc/psqlodbca.so
UsageCount              = 3

[postgress2]
Description             = postgress ODBC Driver
Driver          = /usr/lib/odbc/psqlodbcw.so
Setup           = /usr/lib/odbc/psqlodbcw.so
UsageCount              = 3

But when I start ODBCConfig, and try to add a user DSN using these, I get
an error message about not being able to get the properties for thes.

There does not seem to be a man page for odbcinst.ini.
/etc/odbc.ini is empty, and I don't seem to have a man page for it either.

Any pointers to HOWTO's for this?

-- 
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing in e-mail?




More information about the ubuntu-users mailing list