Correct option is B
Consistency ensures that a transaction brings the database from one valid state to another, maintaining the defined rules, constraints, and relationships.
For example:
If a banking transaction deducts $100 from one account, it must credit $100 to another account to maintain consistency.
Important Key Points:
Consistency guarantees that the database adheres to its integrity rules before and after the transaction. It guarantees that no data integrity constraints are violated, ensuring a consistent state after transaction completion.
Knowledge Booster:
· Atomicity: Focuses on "all-or-nothing" execution of transactions, but does not directly handle the database's consistency. Atomicityensures that a transaction is treated as a single unit, meaning either all operations are completed successfully or none are applied.
· Isolation: Prevents transactions from reading or modifying intermediate states of other ongoing transactions. Isolation ensures that transactions do not interfere with each other when executed concurrently.
· Durability: Relates to the guarantee that once a transaction is committed, its changes are not lost. Durability ensures that the effects of a committed transaction are permanently recorded in the database, even in the case of a system crash.
· Redundancy: Refers to storing duplicate data for fault tolerance but is unrelated to ACID properties.