[Zope] USE TRansaction : _begin()
Michel
michel@titus.u-strasbg.fr
Wed, 02 May 2001 15:48:26 +0200
Hello,
I'm a young user of zope.
I use Zope with SYBASE (we created a Product SybaseDAv2 and it seems to
work perfectly).
Zope created only one connection to sybase and all my Zope users used this
connection to send SQL requests.
Now I would like to modify some tables from my database. I need to use
transaction.
I unchecked "use transaction" into properties of my SybaseDAV2.
I created 3 DTML Methods (begin, commit and rollback) which call a ZSQL
Method (begintran, commitran,rollbacktran) but it doesn't work because the
first user doesn't avoid the second user to modify the same data.
By reading documentation, I found there are these methods implemeted with
my SybaseDAv2 product :
_begin(self)
_finish(self)
_abort(self)
But how can I call them ?
I tried :
<dtml-call SybDA._begin()>
<dtml-call expr="SybDA._begin()">
<dtml-call expr="TM._begin()">
and a lot of other possibilities .... but it doesn't work!!
SybDA is the name of SybaseDAv2 product in my example.
Maybe this will not work too. So How can I use transaction into Zope ?
Could you send me an example ?
Thank you very much for your help
OFFNER Michel
IGBMC
France