473,395 Members | 1,403 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 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 11790
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...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.