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

Reply via email to