On Tuesday 16 October 2007 12:09:17 Antony Joseph wrote:
> Hi all,
>
>
> I am having three updates in my controller.
> i want to do transaction type of update here.
> suppose if my any one of the update gets failed,the controller should not
> update the values in database.

That should be the default-behavior - the whole method is enclosed in a 
transaction. Throwing an arbitrary exception except the HTTPRedirect and 
InternalRedirect will trigger a rollback.

You could then faciliate standard TG exception handling to deal with that 
exception gracefully.

You might also try and invoke

turbogears.database.rollback_all()

although I'm not sure if that's really working.

Diez

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" 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/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to