Computer Science
Differentiate between commit() and rollback() statements.
Python MySQL
1 Like
Answer
| commit() statement | rollback() statement |
|---|---|
| The commit() method is used to permanently save the changes made during a transaction to the database. | The rollback() method is used to undo or revert the changes made by a transaction. |
The syntax is: connection.commit(). | The syntax is: connection.rollback(). |
Answered By
1 Like