B.Tech.
(Computer Science and Engineering)
Semester-IV
Subject: Database and Management System
Subject code: BCO010C
Marks: 64
Unit # 4
Tutorial sheet 7
Sec-A (5x2=10 marks)
1. What are the steps involved in creation and deletion of files, and in writing data to a file?
2. What do you understand by Concurrency Control?
3. Suppose that there is a database system that never fails. Is a recovery manager required for this
System?
4. What is a cascade less schedule?
5. Define these terms: conflict-serializable schedule, view-serializable schedule, strict schedule.
Sec-B (3x7=21 marks)
1. Consider the following schedule of transactions
T1: R(A), W(A), R(B)
T2: R(A), W(B), R(C)
T3: R(C), W(C)
(a) Construct the precedence graph for this schedule.
(b) Check if the schedule is conflict serializable by analyzing the graph.
2. Define deadlock . Explain the necessary conditions for deadlock to occur and discuss the different
strategies for dealing with deadlock, such as deadlock prevention, deadlock avoidance, and deadlock
detection with example
3. a) Consider the following actions taken by transaction T1 on databases X and Y: R(X), W(X), R(Y),
W(Y).
Give an example of another transaction T2 that, if run concurrently to transaction T without some
form of concurrency control, could interfere with T1.
b) Explain how the use of Strict 2PL would prevent interference between the two transactions.
Sec-C (3*11=33 marks)
1. (a) What is the need of Concurrency Control? Explain time stamp ordering protocol with the help of an
example.
(b) Outline two phase locking protocol (2PL) with example.
2. (a) Identify the name of problems of given schedule and justify your answer with the help of suitable
example
T1
T2
R(X)
W(X)
R(Y)
W(X)
R(Y)
Commit
Commit
(b) Explain the following Time Stamping protocol with the help of suitable examples,
i. Ti Request for Read(Q)
ii. Ti Request for Write(Q)
3. Explain why the read-committed isolation level ensures that schedules are cascade-free.