[Zope-DB] Process one PloneFormGen request into many SQL tables
d.schulz81 at gmx.net
Fri Jan 19 08:56:57 EST 2007
if you want to do things like this, you also could use the alchmist product.
However, I think the archetype / plone formgen integration at the moment
is not functional. (ask kapil t. and roché c. for closer info)
You would have to start out with plain zope 3 schema and formlib like in
the alchemist included orgpeople example.
I developed a neat little application that uses the unit of work and
automatic transaction support of sql alchemy and all dependent tables
are deleted, updated and inserted automatically by the mapper
Paul Eipper escribió:
> Hi all !
> I am just starting with using Zope/Plone and mySQL(InnoDB) and am
> hitting every bump on the road as I go :P
> I have a Form (generated with PloneFormGen+DataGridField) and I need
> to send the data entered there into several mySQL tables. I am
> guessing a Python script would be the right thing here.(?)
> My main questions right now are:
> 1) How do I maintain referencial integrity?
> I need to get LAST_INSERT_ID() from the first INSERT to use on the
> following inserts.
> Could I have a ZSQL Method that does the insert and returns the
> generated ID to the Python script?
> 2) Is a ZSQL Method automatically executed as a transaction? Or do I
> need to manually define BEGIN; COMMIT; to guarantee I am getting the
> correct data?
> 3) Where can I find example code (zsql, python scripts) dealing with
> many related tables? All tutorials I found deal with only one table at
> a time, completely ignoring the relational part of the database.
> Thanks !
> Paul Eipper
> Zope-DB mailing list
> Zope-DB at zope.org
More information about the Zope-DB