Transactions and Recovery

A transaction is not only a unit of work but also a unit of recovery. Recovery refers to the database system's ability to get the database back on its feet after a system failure—that is, into the most current state of affairs that can be guaranteed to be consistent.

System failures are those that affect all transactions in progress but don't damage the database physically. Physical damage to a database is caused by media failure; protection against this kind of failure is provided by regularly backing up your database. In the case of system failure, the problem facing the database system's recovery mechanism is to figure out two things:

  • Which transactions were incomplete at the time of the failure and should, therefore, ...

Get Practical SQL Handbook, The: Using SQL Variants, Fourth Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.