What is the purpose of a transaction in a database?
Q1. What is the purpose of a transaction in a database?
Answer: To ensure data consistency
Explanation: A transaction is a sequence of operations that are executed as a single, all-or-nothing unit, ensuring data consistency and integrity.