You are on page 1of 2

Installing pgODBC on Mac OS X

After some problems with earlier version of Postgresl and pgODBC I gave the new version
8.4.100 a try. And after some obstacles due to missing documentations I finally succeded with
it.

The prerequisites you need are


• a running postgresql installation; mine is a postgresql 8.1.5
• iODBC from www.iodbc.org

For the installation I made these steps:


1. Download pgODBC from postgresql.org and untar it.
2. Determine the location of your iodbc-config file. In the following I assume it's part of
the OSX10.5 SDK. Call the configure script as follows: ./configure --with-iodbc=/
Developer/SDKs/MacOSX10.5.sdk/usr/bin/iodbc-config --enable-pthreads
3. After a successful run you can call now make.
4. If this run was succesful, too, you're about to make the last step in installation: sudo
make install
5. A conncetion test can be made using the iodbctest tool. Call it like this: iodbctest
6. Then type a ? in order to get the list of defined ODBC sources.
7. Important! Enter a full qualified DSN string:
"DSN=office;host=localhost;server=localhost;Database=office;UID=;PWD="
8. If the response is like this: Driver: 08.04.0100 (psqlodbcw.so), everything went
fine.
9. Now it's time to configure the ODBC connection. For this task you should call ODBC
Administrator from your Utilities folder. You add a new driver as shown on the hardcopy.
10. Next you should add a new conncetion in ODBC Administrator as shown on the next
hardcopy. In the example I used a local database called office. The userid and password
should be given as you use it when accessing the database by psql.
11. If everything went fine you should be able now to access your postgresql database by
Filemaker using the "ODBC source" option.

You might also like