Rollback is an operation, which changes the current state of the transaction to the previous state. Undo logs are generally required if we want to roll back any of the uncommitted transactions and it plays a major role in Isolation.
For any changes made during a transaction, it must be stored priorly, because they are required if we choose to roll back the transaction.
Entries are made in undo logs when data modifications are done. If a transaction modifies data with SQL commands, It will create discrete undo logs for each operation. Once a transaction is committed MySQL is free to purge the undo logs created in that transaction.
To know more about undo logs, you can check our previous blogs on overview to undo logs.
Usually, the Rollback process will take more time than the original operation. Because …[Read more]