174 views
0 votes
0 votes
Consider the following schedule :

r1(A),r3(D),w1(B),r2(B),r4(B),w2(C),r5(C),w4(E),r5(E),w5(B)

The number of serial schedules which are view equal to schedule (S) ___________.

1 Answer

Best answer
3 votes
3 votes

Total of 5 transactions are here.

Let us try to see any pattern from

1. Initial reads: 

T1 is reading A , which no one is writing.

T3 is reading D, which no one is writing.

// no more initial reads.

What can we say yet? anyone can come at anytime.

2. Updated read:

T2 and T4 are reading B being written by T1.  //  T1-->{T2,T4}

T5 is reading C from T2.    //  T2-->T5

T5 is reading E from T4.   //  T4-->T5

3. Final writes:

T1-->T5 (for B only)

------------------------------

T1-->{T2,T4}-->T5

We can arrange above achedule in 2! ways.

T3 can be placed anywhere // 5 places would be there.

Total schedules are 2! *5 =10.

edited by

No related questions found