DEV Community

Discussion on: A brief example of an SQL serializable transaction

Collapse
 
ludodba profile image
Ludovico Caldara

I would find it unbelievable if, with today's design patterns, one would still rely on serialization. Serialization is the antithesis of scalability, and over the last two decades, I haven't seen a product owner who would rather have a severely underperforming application than have such a write skew.

Collapse
 
franckpachot profile image
Franck Pachot

In PostgreSQL, using the Serializable isolation level may be necessary because the Read Committed isolation level can lead to inconsistent results in case of conflict without read restart. Serializable isolation level also has a scalable implementation, which is a form of optimistic concurrency control.

In Oracle, the Read Committed isolation level is consistent with transparent restarts, and applications can function perfectly fine without needing transaction serializability.

There's no better or worse implementation but it's essential to understand how these isolation levels work in different databases because the ANSI/ISO definitions are obsolete.