Commit & RollBack Operation in Python

PythonServer Side ProgrammingProgramming

COMMIT

Commit is the operation, which gives a green signal to database to finalize the changes, and after this operation, no change can be reverted back.

Here is a simple example to call commit method.

db.commit()

ROLLBACK

If you are not satisfied with one or more of the changes and you want to revert back those changes completely, then use rollback() method.

Here is a simple example to call rollback() method.

db.rollback()
raja
Published on 31-Jan-2020 14:32:15
Advertisements