[Pythonmac-SIG] Help with psycopg2
kent37 at tds.net
Wed Mar 28 17:40:07 CEST 2007
Kent Johnson wrote:
> I am trying to install PostgreSQL and psycopg2. I would like to get this
> working with Python 2.5 and Postgres 8.2.
Update: I was able to build psycopg2 from source and it now imports so I
think I'm all set.
> I installed Postgres from Mark Liyanage's installer:
> I installed psycopg2 from pythonmac:
> When I import psycopg2 I get an error:
> In : import psycopg2
> Traceback (most recent call last):
> File "<ipython console>", line 1, in <module>
> line 60, in <module>
> from _psycopg import BINARY, NUMBER, STRING, DATETIME, ROWID
> <type 'exceptions.ImportError'>:
> 2): Library not loaded: /usr/local/pgsql/lib/libpq.4.dylib
> Referenced from:
> Reason: image not found
> Looking in /usr/local/pgsql/lib/, I find libpq.5.0.dylib and
> libpq.5.dylib but no libpq.4.dylib. Does that mean that this version of
> psycopg2 is linked with a different version of Postgres?
> How can I get this to work? Should I install Postgres from somewhere else?
> I was able to successfully install postgres and psycopg2 using MacPorts
> but their version is for Python 2.4 and Postgres 8.1 so it is less than
> Pythonmac-SIG maillist - Pythonmac-SIG at python.org
More information about the Pythonmac-SIG