What are ACID properties in a SQL transaction?

ACID properties stand for Atomicity, Consistency, Isolation and Durability.

A Transaction is considered reliable, if it has these characteristics.

  • Atomicity: It means all or nothing. A transaction is Atomic, if any part of transaction fails, then whole of the transaction is rolled back. If all the parts of transaction are successful, then only Transaction is committed.
  • Consistency: It means that each Transaction will ensure that Database remains in a valid state. Once the Transaction is complete, it should satisfy all the constraints, triggers, rules etc.
  • Isolation: It means that each transaction can be executed in separately. So it is possible to run a transaction in a concurrent system. An incomplete transaction is not visible to another transaction.
  • Durability: It means that changes done by a Transaction are permanent. Even if the Database crashes or power goes off, the committed Transaction and its results remain stored permanently.

Leave a Reply

Your email address will not be published. Required fields are marked *