Skip to content
Why Database Transactions Use Two-Phase Locking episode artwork

EPISODE · Aug 27, 2026 · 8 MIN

Why Database Transactions Use Two-Phase Locking

from Database Tech with Fexingo: SQL, NoSQL, and Data Storage Conversations · host Fexingo

In this episode, Lucas and Luna dig into two-phase locking—the protocol that keeps database transactions from colliding. They use the example of a bank transfer, where a debit and a credit must happen atomically, to show why locking is more than just 'preventing overwrites.' The conversation walks through the two phases: growing, where locks are only acquired, and shrinking, where locks are only released. They explain why two-phase locking guarantees serializability, and why that guarantee comes at a cost—lock contention, deadlocks, and cascading aborts. They also touch on how modern databases like PostgreSQL and MySQL implement it, and why some systems opt for weaker isolation levels to get more throughput. A practical analogy about a shared hotel room helps ground the concept, and the hosts compare two-phase locking to optimistic concurrency control, familiar from the earlier episode on snapshots. No previous database knowledge needed—just a curious mind. #TwoPhaseLocking #DatabaseTransactions #Serializability #ConcurrencyControl #LockingProtocol #ACID #PostgreSQL #MySQL #DatabaseInternals #DataEngineering #SQL #NoSQL #TransactionIsolation #Deadlock #DatabasePerformance #TechPodcast #FexingoBusiness #BusinessPodcast Keep every episode free: buymeacoffee.com/fexingo

Episode metadata supplied by the publisher feed · Published Aug 27, 2026

Embed this episode

Ready to play

Why Database Transactions Use Two-Phase Locking

0:00 8:47

No transcript for this episode yet

We transcribe on demand. Request one and we'll notify you when it's ready — usually under 10 minutes.

No similar episodes found.

No similar podcasts found.

Frequently Asked Questions

How long is this episode of Database Tech with Fexingo: SQL, NoSQL, and Data Storage Conversations?

This episode is 8 minutes long.

When was this Database Tech with Fexingo: SQL, NoSQL, and Data Storage Conversations episode published?

This episode was published on August 27, 2026.

Can I download this Database Tech with Fexingo: SQL, NoSQL, and Data Storage Conversations episode?

Yes. Use the download control on the episode player to save the publisher-provided media file.
URL copied to clipboard!