473,835 Members | 1,938 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

dll load failed?..pls help

1 New Member
i'm new to python programming..an d 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\Li b\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 11816
leegrube
2 New Member
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..an d 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\Li b\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
kennethEntera
6 New Member
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
leegrube
2 New Member
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
kennethEntera
6 New Member
try using python 2.5 and the pygresql appropriate for python 2.5. this works for me.
Feb 18 '08 #5
kennethEntera
6 New Member
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
4569
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 an error message telling me it could not load the DLL (complete message below) Third, I've read (on activeState site) about someone else having this problem which seemed to be resolved by correctly installing the appropriate versions of...
0
2581
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 usercontrol into the place holder... i dont know why im getting this error:
0
3157
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. --------------------- Load report failed. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information
2
3300
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 Report Viewer, I get a "Load Report Failed" error, and I'm not sure what I can do to resolve it. I know it's not the connection to the data -- I'm able to get a datagrid to display the data just fine after filling a dataset. I tried searching the...
1
4764
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 cmdBehavior, RunBehavior runBehavior, Boolean returnStream) at System.Data.SqlClient.SqlCommand.ExecuteNonQuery() am i missing something that needs to be installed on sql server? is this a
1
2250
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 was used to save viewstate during the previous request. For example, when adding controls dynamically, the controls added during a post-back must match the type and position of the controls added during the initial request
2
4509
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 Panel becomes visible. pnlGridViewSearchList pnlFormView The problem that I am having is that if I set the FormView Panel's
4
8002
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 can't find it. I read some other posts where people said that you have to make sure you have the 64-bit version of LIBAIO and at first, we didn't -- but then we found the 64-bit package and reinstalled it and we still have the problem. We're...
0
1055
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 able to load the shared library without any unresolved symbols. The machine details are as follows: Machine: HP-UX dafne B.11.23 U ia64 Compiler: HP aC++/ANSI C B3910B A.06.05 Python version: 2.4
0
1660
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 item which was selected in the previous run the following error message is displayed.. Please help me in this regard.. Failed to load viewstate. The control tree into which viewstate is being loaded must match the control tree that was used to...
0
10804
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10517
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10558
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10226
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9343
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6961
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5631
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5802
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3990
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.