[Zope-DB] Example for RDB persistency in zope products?
charlie at egenix.com
Fri Jun 25 12:06:27 EDT 2004
you might want to look at something like pgAuthSource in exUserFolder which
allows you to store Zope user objects in a relational database. I am not
sure if it is possible to bypass ZSQL when talking to the DA, this depends
a little on the DA as most of the work is done by shared.ZRDB.aqueduct
which then essentially calls the .query method of the appropriate driver.
On 2004-06-25 at 20:22:36 [+0200], Nick Bower <nicholas.bower at jrc.it> wrote:
> Does anyone have any examples of how I code relational database
> persistency into an object (at a Zope product level)?
> I've an application written to view and manage complex organisational
> data in Python scripts, ZPTs and ZSQL methods, and would like to move it
> to the product level and into persistent object land. However, the RDB
> persistency aspect is what I'm most confused about.
> I've seen people talk about doing the following:
> 1. Inherit from ZSQL methods for their business objects
> 2. Call ZSQL methods from their business object logic
> 3. Using an existing DA, such as psycopg, directly, bypassing ZSQL
> methods, and calling the DA connection methods from business logic
> 4. Writing their own DA for integration with business logic
> 3. would have seemed to me like the practical way to go, but I'm just
> not sure where to start for lack of documentation promoting any way
> other than using ZSQL.
Professional Python Services directly from the Source
>>> Python/Zope Consulting and Support ... http://www.egenix.com/
>>> mxODBC.Zope.Database.Adapter ... http://zope.egenix.com/
>>> mxODBC, mxDateTime, mxTextTools ... http://python.egenix.com/
::: Try mxODBC.Zope.DA for Windows,Linux,Solaris,FreeBSD for free ! ::::
More information about the Zope-DB