[Zope] Re: Python Database API

Tres Seaver tseaver at palladion.com
Mon Nov 20 11:14:00 EST 2006


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Robert (Jamie) Munro wrote:
> Is it possible to get to the python Database API through a database
> connector in zope? I'd like to use things like
> cursor.executemany(sql,seq_of_parameters) to make lots of queries run a
> lot faster.
> 
> I'm using Psycopg if that makes any difference.

It is straightforward to do that from "trusted" product code.  Look at
how the ZSQLMethods work it, in
$SOFTWARE_HOME/Products/ZSQLMethods/SQL.py (they derive from the 'DA'
class in $SOFTWARE_HOME/Shared/DC/ZRDB/DA.py).


Tres.
- --
===================================================================
Tres Seaver          +1 202-558-7113          tseaver at palladion.com
Palladion Software   "Excellence by Design"    http://palladion.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFFYdRI+gerLs4ltQ4RAvaaAKCmOk5Y78xc1lvf35X+hcClamtX+wCg0st4
OfWx3oWZaFhlznGjRs6AXRM=
=uovX
-----END PGP SIGNATURE-----



More information about the Zope mailing list