895 views
0 votes
0 votes

I am getting the answer as c but the given answer is b. How b can be ans, there is a cycle R1x->W1x (s1->s2) and W1y->w1y(s2->s1),so s1,s2 can not be conflict serializable…  i m confused.. what is the right answer?

2 Answers

0 votes
0 votes
Step 1: - first  search for  write operation coming in schedule going sequentially

Step 2 : - traverse first left of that Write and Look for following

  i.  Read operation on same data item

  ii. Whether operation is performed by same transaction or not.

    a) If same transaction continue traversing or

    b) if different transaction, draw a edge from reading transaction to writing transaction

iii. Traverse till you reach first operation in reverse sequence and perform step 2.i and 2.ii

Step 3 :- traverse right to the Write operation we selected in previous step and check for same step 2.i and 2.ii on reaching step "2.ii.b" this time draw a edge from writing transaction and to reading transaction

Step 4 :- repeat the steps 2 and 3 with the selected write operation by a particular transaction but this time look for write operation performed by some other transaction on same varialble as our selected transaction.

Step 5. Finally take a look at graph we got. If anywhere in the graph you find cycle its not conflict serializable. If no cycle, its conflict serializable

Hope this helps...

Related questions

2 votes
2 votes
1 answer
1
aditi19 asked Nov 18, 2018
2,280 views
T1T2T3R(X)W(X)commitW(X)commitR(X)commit is this transaction conflict serializable and view serializable?
0 votes
0 votes
1 answer
2
aditi19 asked Nov 18, 2018
629 views
T1 T2 T3W(Y)commitR(X)R(Y)W(Z)commitW(X)commitis this schedule a strict schedule?
1 votes
1 votes
1 answer
3
aditi19 asked Nov 17, 2018
1,160 views
Tl:W(X), T2:R(X), Tl:W(X), T2:Commit, Tl:Abortis this schedule conflict serializable?
1 votes
1 votes
1 answer
4