[Zope3-dev] Re: [Zope3-Users] mysqldbda database adapter

Andy Dustman farcepest at gmail.com
Sat Mar 19 19:57:23 EST 2005

On Sun, 20 Mar 2005 00:35:31 +0100, Roger Ineichen <dev at projekt01.ch> wrote:

> Take a look at the repository, perhaps this package is working.
> I know only that Stephan was working the last time at the
> sprint in Munich at this package.
> http://svn.zope.org/mysqldbda/

At first glance (mainly at adapter.py), it seems this could be
simplified a bit when using MySQLdb-1.2.0, as you can pass
use_unicode=True in connect and automatically get all strings as
unicode, thus eliminating the need for MySQLStringConverter.

Also, it would be very easy to configure MySQLdb to return the correct
Python types in other cases. MySQLdb.converters.conversions is a
dictionary that maps MySQL numeric column types to callable objects
which convert a string to a Python type. Most of the time, these are
Python built-ins, such as int or float. str is the default action.
1.2.0 uses the Python datetime classes, and it appears ZopeX3 uses
them now, so the only thing that is likely to be needed to be changed
is BLOB columns (returned as array('c',...); Zope probably still wants

For examples of how to do this, look at ZMySQLDA-2.0.9b3.
Computer interfaces should never be made of meat.

Using GMail? Setting Reply-to address to <> disables this annoying feature.

You are in a maze of twisty little passages all alike.
To go north, press 2. To go west, press 4.
To go east, press 6. To go south, press 8. 
If you need assistance, press 0 and a little dwarf
will assist you.

More information about the Zope3-users mailing list