The Backend Engineering Show with Hussein Nasser cover image

All Postgres Locks Explained | A Deep Dive

The Backend Engineering Show with Hussein Nasser

00:00

The Concurrent Locking for No Key Update

This particular lock is acquired when you do a normal update. It will not block for select for key share, because I know that the thing I'm doing is not really updating keys. So this is very similar to for update, but it's weaker. This acquires a shared lock rather than an exclusive lock on the retrieve draw. A shared lock blocks other transaction from performing update delete select for No Key Update. You can't even do that, but it does not prevent select for share and select forkey share.

Transcript
Play full episode

Remember Everything You Learn from Podcasts

Save insights instantly, chat with episodes, and build lasting knowledge - all powered by AI.
App store bannerPlay store banner