Home

LUWs

LUWs stands for Logical Unit of Work, a core concept in transaction processing and database management. A LUW is a sequence of data operations that are intended to be executed as a single, indivisible unit. The defining property is atomicity: either all operations within the LUW succeed and are committed, or none take effect and the system reverts to the state before the LUW began.

Scope and behavior: A LUW can include multiple SQL statements that may touch one or several database

Relationship to ACID: LUWs are designed to uphold the ACID properties—atomicity, consistency, isolation, and durability. They

Operations and usage: In application code, a LUW is typically managed by a transaction API: begin transaction,

Performance considerations: Long-running LUWs can hold locks longer, increasing contention and the risk of deadlocks. Design

Other uses: While LUW most commonly refers to Logical Unit of Work in databases, the exact terminology

objects.
In
systems
that
support
distributed
transactions,
a
LUW
may
span
multiple
resources
and
rely
on
a
two-phase
commit
protocol
to
ensure
atomicity
across
the
resources.
A
LUW
begins
with
the
first
data
modification
in
the
unit
and
ends
with
a
commit
or
rollback.
While
committed,
changes
are
made
durable
and
visible
to
other
transactions
according
to
the
chosen
isolation
level.
provide
a
clear
boundary
for
rollback,
enabling
recovery
to
a
consistent
state
in
case
of
error
or
failure.
execute
statements,
then
commit;
or
rollback
if
an
error
occurs.
Some
systems
offer
savepoints
for
partial
rollback
within
a
LUW,
allowing
finer
control
without
ending
the
entire
unit.
guidance
often
recommends
keeping
LUWs
as
short
as
feasible
and
choosing
an
appropriate
isolation
level
to
balance
data
integrity
with
concurrency.
may
vary
by
platform.
The
concept
remains
central
to
ensuring
reliable,
atomic
changes
across
a
set
of
operations.