• edited by
16,616 views
48 48 votes

Consider the following schedule for transactions $T1, T2$ and $T3:$

$$\begin{array}{|c|c|c|}\hline \textbf{T1} & \textbf{T2} & \textbf{T3} \\\hline  \text{Read(X)} & \text{} & \text{} \\\hline   \text{} & \text{Read(Y)} & \text{} \\\hline  \text{} & \text{} & \text{Read(Y)} \\\hline \text{} & \text{Write(Y)} & \text{} \\\hline  \text{Write(X)} & \text{} & \text{} \\\hline  \text{} & \text{} & \text{Write(X)} \\\hline  \text{} & \text{Read(X)} & \text{} \\\hline \text{} & \text{Write(X)} & \text{} \\\hline\end{array}$$
Which one of the schedules below is the correct serialization of the above?

  1. $T1 \to T3 \to T2$
  2. $T2 \to T1 \to T3$
  3. $T2 \to T3 \to T1$
  4. $T3 \to T1 \to T2$

5 Answers

Best answer
66 66 votes

Answer is option A.

create precedence graph and apply Topological sort on it to obtain 
$T1 \rightarrow T3 \rightarrow T2$

• edited by
9 9 votes

The solution is described here.
            
hence option A is True.

• edited
6 6 votes
You can use method of conflict serializability graph or precedence graph Ref: Elmasri Navathe. Then serialisation is T1 T3 T2
1 flag:
✌ Low quality (RahulVerma3 “blind write is there”)
0 0 votes
(A) T1→T3→T2

T1 can complete before T2 and T3 as there is no conflict between Write(X) of T1 and the operations in T2 and T3 which occur before Write(X) of T1 in the above diagram.
T3 should can complete before T2 as the Read(Y) of T3 doesn’t conflict with Read(Y) of T2. Similarly, Write(X) of T3 doesn’t conflict with Read(Y) and Write(Y) operations of T2.
0 0 votes

CHECK FOR VIEW SERIALIZABILITY HERE . NOT CONFLICT SERIALIZABILITY

 

CHECK FOR CONFLICT SERIALIZABILITY IS MAJOR MISCONCEPTION HERE .

 

THIS IS CORRECT ANSWER OF THIS QUESTION WITH CORRECT CONCEPT .

ago
Answer:
Position:
Show:

Related questions

72 72 votes
8 answers 8 answers
33.5k
33.5k views
go_editor asked Sep 29, 2014
33,484 views
Which of the following concurrency control protocols ensure both conflict serializability and freedom from deadlock?$2$-phase lockingTime-stamp orderingI onlyII onlyBoth ...
74 74 votes
11 answers 11 answers
26.4k
26.4k views
go_editor asked Sep 30, 2014
26,374 views
The following functional dependencies hold for relations $R(A, B, C)$ and $S(B, D, E).$ $ B \to A$$A \to C$The relation $R$ contains $200$ tuples and the relation $S$ con...
48 48 votes
2 answers 2 answers
13.1k
13.1k views
go_editor asked Sep 29, 2014
13,121 views
A relational schema for a train reservation database is given below.passenger(pid, pname, age)reservation(pid, class, tid)$$\overset{\text{Passenger}}{\begin{array}{|c|c|...
97 97 votes
10 answers 10 answers
40.8k
40.8k views
go_editor asked Apr 21, 2016
40,804 views
A computer system has an $L1$ cache, an $L2$ cache, and a main memory unit connected as shown below. The block size in $L1$ cache is $4$ words. The block size in $L2$ cac...