Transaction Design
The design of application transactions is very important, because a transaction's design can directly affect database integrity and the performance of applications. The following sections discuss several issues to consider when designing a database application's transactions.
Units of Work
Remember that a transaction is meant to encompass many closely related SQL statements that, together, perform a single unit of work as defined by the application's business rules. More specifically, a transaction should not encompass multiple units of work, nor should it encompass a partial unit of work.
For example, consider an application that should independently allow the input of customers, parts, and orders with their corresponding line ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access