Hello, I want to know if open a transaction inside another is safe and
encouraged?
I have a method:
def foo():
session.begin
try:
stuffs
except Exception, e:
session.rollback()
raise e
session.commit()
and a method that calls the first one, inside a transaction:
def bar():
stuffs
try:
foo()
stuffs
except Exception, e:
session.rollback()
raise e
session.commit()
if I get and exception on the foo method, all the operations will be
rolled back? and everything else will work just fine?
thanks!!
--
You received this message because you are subscribed to the Google Groups
"sqlalchemy" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sqlalchemy?hl=en.