472,364 Members | 2,222 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,364 software developers and data experts.

dll load failed?..pls help

1
i'm new to python programming..and i'm studying into one of its tutorials..I used pygres for its interface to the postgresql database..the problem is when i tried to run "import _pg" it has an error like this:

Traceback (most recent call last):
File "<pyshell#0>", line 1, in -toplevel-
import pg
File "C:\Python24\Lib\site-packages\pg.py", line 21, in -toplevel-
from _pg import *
ImportError: DLL load failed: The specified module could not be found.

ive checked the installation directory and i dont see any problem there..i couldnt figure out what is really the problem here..pls help..
Sep 18 '06 #1
5 11658
I am in the same spot you were in. Did you ever get an answer or figure it out?

Thanks in advance.

i'm new to python programming..and i'm studying into one of its tutorials..I used pygres for its interface to the postgresql database..the problem is when i tried to run "import _pg" it has an error like this:

Traceback (most recent call last):
File "<pyshell#0>", line 1, in -toplevel-
import pg
File "C:\Python24\Lib\site-packages\pg.py", line 21, in -toplevel-
from _pg import *
ImportError: DLL load failed: The specified module could not be found.

ive checked the installation directory and i dont see any problem there..i couldnt figure out what is really the problem here..pls help..
Jan 19 '08 #2
actually im using pygresql also before going to the dll, copy the dll found in the postgresql library ahm it is found in the program files in c then postgresql/8.1/lib dn copy all the dll there then paste to the python directory where the pg module is found
Jan 21 '08 #3
Thanks for the help Kenneth. I copied all the DLLs in the PostgreSQL\8.2\lib (there wasn't an '_pg.dll') folder to Python\Lib\site-packages (the only 'pg.*' files were pg.pyc & pg.pyo).

I tried to run my code again and got the same message

I'm an old school coder and DBA, but completely new OO and Python, so pardon me if I am being dense...

Also, I opened pg.pyc and saw a note which said it included the _pg module, so I added an 'import pg' stmt into my code. I ran and had the same error with that module.

This is a little frustrating.
Jan 21 '08 #4
try using python 2.5 and the pygresql appropriate for python 2.5. this works for me.
Feb 18 '08 #5
i think _pg.dll is already in the nstaller of pygresql. i have _pg.dll found in my python25/lib/site_packages directory
Feb 18 '08 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: jmdeschamps | last post by:
Hello Having cx_Oracle (an Oracle database connector for Python) used it here where I teach for the last couple of years, and finding it so easy to use (and install) I was taken aback when I got...
0
by: Josema | last post by:
Hi to all, I have a webform.aspx and inside i have a dropdown list with autopostback and a place holder... Depending of the selected index that the user selects in the dropdownlist i load a...
0
by: Simon | last post by:
Hi I try to open a CR report file located on the network path from a web form developed with vs2003 and CR for Visual Studio, but the Load method of ReportDocument object always return error. ...
2
by: Jeff_Mac | last post by:
Hi there. I'm a bit of a newbie, and I would appreciate any help that anyone can give me on an error I'm getting with Crystal Reports. Every time I attempt to view a report using the Crystal...
1
by: Daniel | last post by:
ADO.NET Failed to load msxmlsql.dll How to fix this error? System.Data.SqlClient.SqlException: Failed to load msxmlsql.dll. at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior...
1
by: rockdale | last post by:
Sometime my ASP.NET application got this error message but not always everytime. Failed to load viewstate. The control tree into which viewstate is being loaded must match the control tree that...
2
by: sck10 | last post by:
Hello, I have a web page that has a GridView and a FormView, each in its own panel. The GridView shows a list of records in a database. When a row in the GridView is selected the FormView...
4
by: gwise | last post by:
I'm trying to use LINUXAIO on my EMT64 db2 v9 FP 2 database server, but I keep getting the following error in my db2diag.log. Funny thing, the file is actually in /usr/lib. For some reason DB2...
0
by: bbansi_1982 | last post by:
Hi, I have built DCOracle2 with python. But when i try to import dco2 inside python prompt it gives me the error Failed to load dco2.sl although it has been built properly and dlopen is also...
0
by: nithagowda | last post by:
Hello, I have a DropDownList for source type and a panel for displaying TreeView based on the source type.. The problem is- if i select different source type drom ddlSrcType, other than the...
2
by: Kemmylinns12 | last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and efficiency. While initially associated with cryptocurrencies...
0
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was proposed, which integrated multiple engines and...
0
by: Arjunsri | last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and credentials and received a successful connection...
0
hi
by: WisdomUfot | last post by:
It's an interesting question you've got about how Gmail hides the HTTP referrer when a link in an email is clicked. While I don't have the specific technical details, Gmail likely implements measures...
1
by: Matthew3360 | last post by:
Hi, I have been trying to connect to a local host using php curl. But I am finding it hard to do this. I am doing the curl get request from my web server and have made sure to enable curl. I get a...
0
Oralloy
by: Oralloy | last post by:
Hello Folks, I am trying to hook up a CPU which I designed using SystemC to I/O pins on an FPGA. My problem (spelled failure) is with the synthesis of my design into a bitstream, not the C++...
0
BLUEPANDA
by: BLUEPANDA | last post by:
At BluePanda Dev, we're passionate about building high-quality software and sharing our knowledge with the community. That's why we've created a SaaS starter kit that's not only easy to use but also...
2
by: Ricardo de Mila | last post by:
Dear people, good afternoon... I have a form in msAccess with lots of controls and a specific routine must be triggered if the mouse_down event happens in any control. Than I need to discover what...
1
by: ezappsrUS | last post by:
Hi, I wonder if someone knows where I am going wrong below. I have a continuous form and two labels where only one would be visible depending on the checkbox being checked or not. Below is the...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.