pyPgSQL giving error!

G

Gurpreet Sachdeva

I am using Redhat 9.0/python2.3. I installed pyPgSQL-2.4.tar.gz and it
was successfull. Now when I am trying to import that module, I got:

Python 2.3.3 (#1, Jan 11 2005, 15:24:09)
[GCC 3.2.2 20030222 (Red Hat Linux 3.2.2-5)] on linux2
Type "help", "copyright", "credits" or "license" for more information.Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "pyPgSQL/PgSQL.py", line 391, in ?
from libpq import *
File "pyPgSQL/libpq/__init__.py", line 23, in ?
from libpq import *
ImportError: No module named libpq

I tried googling also but couldn't get the answere.
Please help...

~Garry
 
H

Harald Massa

I am using Redhat 9.0/python2.3. I installed pyPgSQL-2.4.tar.gz and it
was successfull. Now when I am trying to import that module, I got:
Type "help", "copyright", "credits" or "license" for more information.
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "pyPgSQL/PgSQL.py", line 391, in ?
from libpq import *
File "pyPgSQL/libpq/__init__.py", line 23, in ?
from libpq import *
ImportError: No module named libpq

did you really do ./configure, make and make install?

where is libpq.*

was a postgres installation present while doing ./configure et all?
 
G

Gurpreet Sachdeva

did you really do ./configure, make and make install?
No, I did python setup.py build and python setup.py install
where is libpq.*
linpq is there in /usr/lib/python2.3/site-packages/pyPgSQL/
was a postgres installation present while doing ./configure et all?

No, But I installed postgresql-libs before installing pyPgSQL

Regards,
Garry
 
G

Gurpreet Sachdeva

And now when I did...

cd /usr/local/lib/python2.3/site-packages/pyPgSQL/libpq/

[root@linux libpq]# python __init__.py
Traceback (most recent call last):
File "__init__.py", line 23, in ?
from libpq import *
ImportError: ./libpqmodule.so: undefined symbol: PyUnicodeUCS2_EncodeDecimal

What is this error??? I saw this error sometimes back... Please help...

Thanks,
Garry
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top