A transaction is a unit of work that is performed against a database. Transactions are units or sequences of work accomplished in a logical order, whether in a manual fashion by a user or automatically by some sort of a database program.
A transaction is the propagation of one or more changes to the database. For example, if you are creating a record or updating a record or deleting a record from the table, then you are performing transaction on the table. It is important to control transactions to ensure data integrity and to handle database errors.
Properties of Transactions
Transactions have the following four standard properties, usually referred to by the acronym ACID:
1. Atomicity: ensures that all operations within the work unit are completed successfully; otherwise, the transaction is aborted at the point of failure, and previous operations are rolled back to their former state.
2. Consistency: ensures that the database properly changes states upon a successfully committed transaction.
3. Isolation: enables transactions to operate independently of and transparent to each other.
4. Durability: ensures that the result or effect of a committed transaction persists in case of a system failure.
No comments:
Post a Comment