Data Consistency - Transaction Consistency

Transaction Consistency

A transaction is a logical unit of work that may include any number of file or database updates. Transaction consistency is also frequently referred to as atomicity.

A good example of the importance of transaction consistency is a database that handles the transfer of money.

Suppose a money transfer requires two operations: writing a debit in one place, and a credit in another.

If the system crashes or shuts down when one operation has completed but the other has not, and there is nothing in place to correct this, the system can be said to lack transaction consistency.

With a money transfer, it is desirable that either the entire transaction completes, or none of it completes. Both of these scenarios keep the balance in check.

Transaction consistency ensures just that - that a system is programmed to be able to detect incomplete transactions when powered on, and undo (or "roll back") the portion of any incomplete transactions that are found.

Read more about this topic:  Data Consistency

Famous quotes containing the word consistency:

    All religions have honored the beggar. For he proves that in a matter at the same time as prosaic and holy, banal and regenerative as the giving of alms, intellect and morality, consistency and principles are miserably inadequate.
    Walter Benjamin (1892–1940)