[Zope-DB] Are transactions/atomicity implicit in ZSQL+ Oracle ?
Thu, 21 Mar 2002 15:47:38 +0100 (MET)
En réponse à kapil thangavelu <firstname.lastname@example.org>:
> > > it would be much better to use a sequence. the above is only safe in
> > > transaction serialized mode.
> > Unfortunately I can't modify the db structure or even add simple
> > My question is precisely this: is there explicit LOCKing to do to
> > serialization or does Zope do it automatically for all SQL statements
> in a
> > single ZSQL method?
> zope doesn't do any locking per say, it tries to handle transaction
> integration to make all methods invoked during a request happen
> > If the Oracle DA supports transactions, which I guess it does, am I
> > to assume that the 2 SQL statements inside my ZSQL method are an
> > operation ?
> you can assume transactionality. zope's transaction boundary is at the
> end of
> an http request where it will attempt to commit to all db adapters
> during a request. which means all zsql methods involved in a http
> request are
> associated with a single transaction. of course this is not true if you
> manually manipulating the transaction.
> atomicity, depends on what you're doing and how you've set up the
> connection/env, specifically its transaction isolation level.
I'm not in control of the Oracle+ZOracleDA installation, but my guess is that
it's pretty much everything by default.
What are the different transaction isolation levels ?
Another question: would atomicity be better insured if I nested the SELECT
statement inside the INSERT ? (ie: INSERT INTO table VALUES (SELECT ...., ....)