IT lexicon › Database › Write lock

Write lock

Database På svenska → Updated: 2026-11-11

An exclusive lock type that prevents other transactions from reading or writing the same data while the lock is held.

A write lock (also called an exclusive lock) is the most restrictive lock type in classical databases. Only one transaction can hold a write lock on a row at any moment, and no other transaction can read or write it while the lock is active. This ensures complete isolation during data modification. Write locks often start as read locks that are later upgraded when the transaction attempts to modify data. They are expensive in terms of concurrency because they block all competing access, but they are necessary to guarantee data consistency and prevent lost updates.

← Back to the lexicon