Serializability is a correctness rule for concurrent transaction schedules. A non-serial schedule is considered serializable when its final effect is equivalent to some serial execution of the same transactions. The two major forms are conflict serializability and view serializability. Conflict serializability is tested with conflicting operations and a precedence graph, while view serializability compares initial reads, read-from relationships and final writes. This chapter explains schedules, conflicts, precedence graphs, blind writes and solved schedule problems in very easy language.
What Is Serializability in DBMS?
Serializability is the property that makes a concurrent schedule behave like some serial schedule. Transactions may be interleaved for better performance, but the result should still be logically equivalent to executing those transactions one after another in a safe order.
Suppose T1 and T2 run at the same time. A serial schedule would complete all operations of T1 before T2, or all of T2 before T1. A serializable non-serial schedule may mix their operations, but its effect must still match one valid serial order.
Memory line
Concurrent execution + serial-like correctness = serializabilityBefore this chapter, revise Transactions & ACID Properties in DBMS because serializability mainly protects the Isolation part of ACID.
How to Read a Transaction Schedule
DBMS books usually use short notation:
Example schedule:
R1(X), W1(X), R2(X), W2(X)
The subscript tells you which transaction performs the operation.
What Is a Schedule in DBMS?
A schedule is the order in which operations from one or more transactions are executed, while preserving the original order of operations inside each individual transaction.
Suppose:
T1: R1(X), W1(X)
T2: R2(X), W2(X)
One schedule may be:
Another schedule may interleave their operations. The DBMS must decide whether such interleaving is safe.
Serial Schedule and Non-Serial Schedule
Serial Schedule
One transaction finishes completely before the next transaction starts.
T1 complete
then
T2 complete
Non-Serial Schedule
Operations from multiple transactions are interleaved.
T1 operation
T2 operation
T1 operation
T2 operation
Serial schedules are easy to reason about but may waste concurrency. Non-serial schedules improve resource use, but only safe ones should be allowed.
Why Do We Need Serializability?
Running every transaction serially can reduce throughput because one transaction may wait while another is using a different resource. Concurrency improves performance, but careless interleaving can create wrong results.
What Are Conflicting Operations?
Two operations conflict when they belong to different transactions, access the same data item and at least one of them is a WRITE.
| Pair | Same item? | Any WRITE? | Conflict? |
|---|---|---|---|
| R1(X), R2(X) | Yes | No | No |
| R1(X), W2(X) | Yes | Yes | Yes |
| W1(X), R2(X) | Yes | Yes | Yes |
| W1(X), W2(X) | Yes | Yes | Yes |
| W1(X), R2(Y) | No | Yes | No |
Why Order Matters for Conflicting Operations
W1(X)
T1 writes X first.
W2(X)
T2 writes X later.
If we swap these two writes, the final value of X may change. That is why their relative order matters.
In contrast, two reads of X can usually swap without changing the database result because neither read modifies X.
What Is Conflict Equivalence?
Two schedules are conflict-equivalent when they contain the same operations and preserve the relative order of every pair of conflicting operations.
A schedule is conflict-serializable if it is conflict-equivalent to some serial schedule.
Conflict serializability shortcut
Can this schedule be rearranged into a serial schedule by swapping only non-conflicting operations?Precedence Graph or Serialization Graph
The precedence graph is the standard method for testing conflict serializability. Create one node for each transaction and draw a directed edge Ti -> Tj when a conflicting operation of Ti occurs before a conflicting operation of Tj on the same item.
How to Test Conflict Serializability
Conflict-Serializable Schedule Example
Consider:
S1:
R1(X)
W1(X)
R2(X)
W2(X)
R1(Y)
W1(Y)
Conflicts on X:
W1(X) before R2(X) => T1 -> T2
W1(X) before W2(X) => T1 -> T2
R1(X) before W2(X) => T1 -> T2
T2 does not access Y, so the later operations of T1 on Y do not create a reverse edge.
There is no cycle. Therefore S1 is conflict-serializable.
Non-Conflict-Serializable Schedule Example
Consider:
S2:
R1(X)
R2(X)
W1(X)
W2(X)
Now inspect the conflicts:
R2(X) before W1(X) => T2 -> T1
R1(X) before W2(X) => T1 -> T2
W1(X) before W2(X) => T1 -> T2
This creates a cycle.
Schedule Analyzer
Click a case to see the schedule, graph idea and serializability result.
Case A: Acyclic conflict graph
Verdict
What Is View Serializability?
A schedule is view-serializable if it is view-equivalent to some serial schedule. View equivalence focuses on which transaction reads the initial value, which write each read gets its value from, and which transaction performs the final write.
View serializability is broader than conflict serializability. Every conflict-serializable schedule is view-serializable, but some view-serializable schedules are not conflict-serializable.
When Are Two Schedules View-Equivalent?
What Is a Blind Write?
A blind write happens when a transaction writes a data item without first reading that item inside the transaction.
W1(X)
If T1 writes X without an earlier R1(X), that write is blind.
Blind writes are important because they create cases that may be view-serializable even when the conflict graph contains a cycle.
View-Serializable but Not Conflict-Serializable Example
Consider this schedule:
S3:
W1(X)
W2(X)
W1(X)
All three operations are blind writes.
Conflict test
First W1(X) before W2(X) => T1 -> T2
W2(X) before final W1(X) => T2 -> T1
The graph has a cycle, so S3 is not conflict-serializable.
View test
There are no reads, so the initial-read and read-from conditions do not add restrictions. The final write on X is performed by T1.
The serial order T2 then T1 also ends with T1 as the final writer of X.
Conflict Serializability vs View Serializability
| Point | Conflict Serializability | View Serializability |
|---|---|---|
| Main idea | Preserve order of conflicting operations | Preserve read-from behavior and final writes |
| Common test | Precedence graph | View-equivalence conditions |
| Cycle rule | Cycle means not conflict-serializable | No simple cycle test for general view serializability |
| Blind writes | Can create cycles | May still allow view equivalence |
| Relationship | Every conflict-serializable schedule is view-serializable | Not every view-serializable schedule is conflict-serializable |
| Practical use | Easier to test and widely used in theory/implementation reasoning | More general but harder to test |
Relationship Between Conflict and View Serializability
Conflict-serializable
Always view-serializable.
View-serializable
May or may not be conflict-serializable.
How to Find the Equivalent Serial Order
If the precedence graph is acyclic, perform a topological ordering.
Example graph:
T1 -> T2
T1 -> T3
T2 -> T3
A valid serial order is:
T1, T2, T3
If a graph has more than one valid topological order, the schedule may be conflict-equivalent to more than one serial order.
Conflict Serializability With T1, T2 and T3
Consider:
S4:
R1(X)
W1(X)
R2(X)
W2(X)
R3(X)
W3(X)
Relevant edges are:
T1 -> T2
T1 -> T3
T2 -> T3
The graph is acyclic.
Serializability vs Recoverability
Serializability and recoverability are different properties. Serializability asks whether concurrent execution is equivalent to a serial execution. Recoverability asks whether commits and reads are ordered safely when one transaction depends on another transaction's data.
Serializability
Focuses on correctness of interleaved operations.
Recoverability
Focuses on safe commit and rollback dependencies.
A schedule should ideally satisfy both the required serializability and recovery properties. Recoverable, cascadeless and strict schedules are usually studied immediately after this topic.
How Serializability Supports Isolation
The Isolation property of ACID says concurrent transactions should not interfere in an unsafe way. Serializability gives a formal model for this idea by requiring a concurrent schedule to behave like some serial order.
Real DBMS products also provide isolation levels and concurrency-control mechanisms such as locking and MVCC. Some isolation levels may allow behavior that is weaker than full serializability.
For the foundation, revise Transactions & ACID Properties in DBMS.
How to Solve Serializability Questions in Exams
Serializability Mistakes to Avoid
How to Write Serializability in Semester Exams
Definition
Define serializability and mention serial-equivalent concurrent execution.
Conflict method
Define conflicts, draw a small precedence graph and explain the cycle rule.
Full answer
Explain serial/non-serial schedules, conflict serializability, view serializability, graph method, blind writes and solve one schedule.
For better university presentation, use How to Write High-Scoring Answers in University Semester Exams. For deciding which questions need more revision, use the previous-year-paper priority method.
Practice Questions With Answers
1. What is serializability in DBMS?
Serializability is the property that makes a concurrent schedule equivalent in effect to some serial schedule.
2. What is a serial schedule?
A serial schedule completes one transaction before starting the operations of another transaction.
3. When do two operations conflict?
They conflict when they belong to different transactions, access the same data item and at least one operation is a write.
4. What is conflict serializability?
A schedule is conflict-serializable if it is conflict-equivalent to some serial schedule.
5. How do you test conflict serializability?
Build a precedence graph. If the graph is acyclic, the schedule is conflict-serializable.
6. What is view serializability?
A schedule is view-serializable if it is view-equivalent to some serial schedule.
7. What is a blind write?
A blind write occurs when a transaction writes a data item without first reading that item in the transaction.
8. Is every conflict-serializable schedule view-serializable?
Yes. Conflict serializability is a subset of view serializability.
9. Does a cycle in the precedence graph mean the schedule is not view-serializable?
No. A cycle proves that the schedule is not conflict-serializable. Some schedules with blind writes can still be view-serializable.
10. What should I study after serializability?
Study recoverable, cascadeless and strict schedules, then locking protocols, two-phase locking, deadlocks and timestamp-based concurrency control.
Serializability One-Minute Revision Sheet
Ultimate memory line
Conflict = graph and cycles · View = who read from whom and who wrote lastFrequently Asked Questions
What is serializability in DBMS in simple words?
Serializability means a concurrent schedule gives a result equivalent to some correct serial order of the same transactions.
What is conflict serializability?
Conflict serializability means a schedule can be made equivalent to a serial schedule by preserving the order of all conflicting operations.
How do you check conflict serializability?
Create a precedence graph. If the graph has no directed cycle, the schedule is conflict-serializable.
What is view serializability?
View serializability checks whether a schedule has the same initial reads, read-from relationships and final writes as some serial schedule.
What is the difference between conflict and view serializability?
Conflict serializability is based on the order of conflicting operations and can be tested using a precedence graph. View serializability is more general and is based on read-from behavior and final writes.
Can a schedule be view-serializable but not conflict-serializable?
Yes. This can happen in schedules containing blind writes.
What Should You Learn Next?
Next: Recoverable, Cascadeless & Strict Schedules
You now know how to judge the logical correctness of concurrent schedules. The next step is checking whether transactions can safely commit or roll back when they depend on each other's data. After that, study locking protocols, Two-Phase Locking (2PL), deadlocks, timestamps and MVCC.
For video revision after reading, use the DBMS YouTube study guide only as a secondary resource.
