[Zope] Problem for extracting long text with zsql method?

McDonnell, Larry lmcdonnell@protonenergy.com
Mon, 20 Jan 2003 12:04:19 -0500


Hi,

I have just recently went through this and was able to get it to work (with
alot of help from Charlie Clark). But I used 0.9.2.win32-py2.1.exe since
this is what Zope is using for it's Python. 

First load MySQL - mysql-3.23.54-win.zip
Next load Python 2.1 - Python-2.1.exe
Next, perform the following:

This is from "Crosbie Fitch" - 

http://sourceforge.net/forum/forum.php?thread_id=621106&forum_id=70461

which provides a fix.

By: locquet ( Bertrand LOCQUET )
 RE: Install Win32 Pythonware Distro
2002-10-03 07:36
I found a solution
Before installing MySQL-python-0.9.2.win32-py2.1.exe
Just add an entry to you register base :
[HKEY_LOCAL_MACHINE\SOFTWARE\Python\PythonCore\2.1\InstallPath]
@="C:\\Program Files\\WebSite\\bin"

Replace the default value @= with the path to you python.exe installed with
Zope.

 Copy the following files from my Python 2.1 directory to
 c:\zope\lib\python:
 CompatMysqldb.py
 CompatMysqldb.pyc
 CompatMysqldb.pyo
 _mysql.pyd
 _mysql_exceptions.py
 _mysql_exceptions.pyc
 _mysql_exceptions.pyo
 MySQLdb (the entire directory)

Install 0.9.2.win32-py2.1.exe and unzip the tar ZMySQLDA-2.0.8.tar.gz to the
\zope\lib\python\product area.
Restart Zope. I had a bad file in the ZMySQLDA-2.0.8.tar.gz where I had most
of my problems. Good Luck.



-----Original Message-----
From: zope-admin@zope.org [mailto:zope-admin@zope.org]On Behalf Of
b.nguyen@chime.ucl.ac.uk
Sent: Monday, January 20, 2003 11:38 AM
To: Chris Withers
Cc: zope@zope.org
Subject: Re: [Zope] Problem for extracting long text with zsql method?


Hi Chris,

Thanks for the suggestions.  

Sorry for my typing mistake in my first email, I am actually using Zope
2.6.0.  

I have installed the suggested modules ZMySQLDA-2.0.8.tar.gz and
MySQL-python-
0.9.2.win32-py2.2.exe.  But I got the following error :

...Zope could not import Products.ZMySQLDA
Traceback (innermost last): 
Module OFS.Application, line 541, in import_product 

Module Products.ZMySQLDA, line 91, in ?
Module Products.ZMySQLDA.DA, line 92, in ? File
Module Products.ZMySQLDA.db, line 89, in ? 
ImportError: No module named _mysql 

I have seen other people posted the same error message in the mail archives,
but I 
didn't see a suitable solution for it.  Would you have any idea?  

Anyway, if anyone has solve the problem, please email me.  


cheers,
Bonnie



On 20 Jan 2003 at 15:24, Chris Withers wrote:

> b.nguyen@chime.ucl.ac.uk wrote:
> > I am running Zope 2.0 in my machine with platform Win XP.   I have
succeed in 
> > connecting Zope to mysql database (which is currently held in another
machine, Unix 
> > server) by using ZODBCDA-3.1.0b2-win32-py21.
> 
> Why not just to ZMySQLDA (you'll need mysql-python too) directly:
> http://sourceforge.net/projects/mysql-python
> 
> I'd echo Deiter's comments about upgrading to 2.5.1 or 2.6.0...
> 
> cheers,
> 
> Chris
> 



_______________________________________________
Zope maillist  -  Zope@zope.org
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )