Purpose
Databases and other data stores which treat the integrity of data as paramount often include the ability to handle transactions to maintain the integrity of data. A single transaction consists of one or more independent units of work, each reading and/or writing information to a database or other data store. When this happens it is often important to ensure that all such processing leaves the database or data store in a consistent state.
Examples from double-entry accounting systems often illustrate the concept of transactions. In double-entry accounting every debit requires the recording of an associated credit. If one writes a check for €100 to buy groceries, a transactional double-entry accounting system must record the following two entries to cover the single transaction:
- Debit €100 to Groceries Expense Account
- Credit €100 to Checking Account
A transactional system would make both entries pass or both entries would fail. By treating the recording of multiple entries as an atomic transactional unit of work the system maintains the integrity of the data recorded. In other words, nobody ends up with a situation in which a debit is recorded but no associated credit is recorded, or vice versa.
Read more about this topic: Database Transaction
Famous quotes containing the word purpose:
“...Often the accurate answer to a usage question begins, It depends. And what it depends on most often is where you are, who you are, who your listeners or readers are, and what your purpose in speaking or writing is.”
—Kenneth G. Wilson (b. 1923)
“We need not only a purpose in life to give meaning to our existence but also something to give meaning to our suffering. We need as much something to suffer for as something to live for.”
—Eric Hoffer (19021983)
“The purpose of punishment is to improve those who do the punishingthat is the final recourse of those who support punishment.”
—Friedrich Nietzsche (18441900)