engineering computer science MCQ #810

What is the purpose of the ROLLBACK statement?

engineering computer science MCQ #810

  1. Question 1

    Q1. What is the purpose of the ROLLBACK statement?

    • A) To save changes made by a transaction
    • B) To cancel a transaction and restore the database to its previous state
    • C) To start a new transaction
    • D) To commit a transaction

    Answer: To cancel a transaction and restore the database to its previous state

    Explanation: ROLLBACK statement cancels a transaction and restores the database to its previous state, undoing all changes made by the transaction.