Avatar of SStory
SStory
Flag for United States of America

asked on 

Examples and Explanation of Transaction and Rollback for MySQL 5.0

It sounds crazy, but I can't find any examples of how to know when to rollback in a transaction.
It is obvious that you do ROLLBACK to do it, but when?

I have some INSERTS, UPDATES, etc. that need to take place in a transaction.  This is MySQL 5.0 inside of a Stored Procedure or Stored Function.  What do I do to test for failure on these and rollback?  Please provide examples.

Thanks
MySQL Server

Avatar of undefined
Last Comment
SStory

8/22/2022 - Mon