Subject Re: ACID
Author Helen Borrie
Paul Schmidt and all others interested:

I hope Ann won't mind if I repost here her interesting response to a question I asked her a few weeks ago...i
--------------------------------------------------------------------------------------------
The buzzword here is ACID - which stands for something...
This was lifted from the NuSphere site (Progress's attempt
to improve MySQL).

n the context of database transactions, ACID is an acronym for Atomic,
Consistent, Isolation, and Durable. Transactions provide a simple model of
success or failure. A transaction either commits (i.e. all its actions happen),
or it aborts (i.e. all its actions are undone). This all-or-nothing quality makes
for a simple programming model. The attributes of an ACID transaction are:


Atomicity

A transaction allows for the grouping of one or more
changes to tables and rows in the database to form an
atomic or indivisible operation. That is, either all of the
changes occur or none of them do. If for any reason the
transaction cannot be completed, everything this
transaction changed can be restored to the state it was
in prior to the start of the transaction via a rollback
operation.



Consistency

Transactions always operate on a consistent view of
the data and when they end always leave the data in a
consistent state. Data may be said to be consistent as
long as it conforms to a set of invariants, such as no
two rows in the customer table have the same
customer id and all orders have an associated
customer row. While a transaction executes these
invariants may be violated, but no other transaction will
be allowed to see these inconsistencies, and all such
inconsistencies will have been eliminated by the time
the transaction ends.



Isolation

To a given transaction, it should appear as though it is
running all by itself on the database. The effects of
concurrently running transactions are invisible to this
transaction, and the effects of this transaction are
invisible to others until the transaction is committed.



Durability

Once a transaction is committed, its effects are
guaranteed to persist even in the event of subsequent
system failures. Until the transaction commits, not
only are any changes made by that transaction not
durable, but are guaranteed not to persist in the face of
a system failure, as crash recovery will rollback their
effects.





Regards,

Ann
www.ibphoenix.com
We have answers.