Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Assume that objects a1, a2, and a3 are managed by a server. There are two operations provided by the server for operating the objects. read(a)

Assume that objects a1, a2, and a3 are managed by a server. There are two operations provided by the server for operating the objects.

read(a) returns the value of a

write(a, v) assigns v to a

Assume that the following two concurrent transactions T and U are performed on these objects.

T: read(a2); read(a1); write(a2, a2+85); write(a1, a1-32)

U: read(a2); write(a2, a2-34); read(a3); write(a3, a3-77)

Assume that the original values of a1, a2, and a3 are 124, 156, and 133 respectively.

(a) If the interleaving operations from T and U are serially equivalent to T before U, what are the values of a1, a2 and a3 after the two transactions have completed?

(b) For serial equivalence of T before U, give a possible order of interleaving operations from T and U.

(c) If the interleaving operations from T and U are serially equivalent to U before T, what are the values of a1, a2 and a3 after the two transactions have completed? (d) For serial equivalence of U before T, give a possible order of interleaving operations from T and U.

(e) Give an example of interleaving operations from T and U, which are not serially equivalent and cause the lost update problem.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions

Question

=+What is the nature of the unions in the particular country?

Answered: 1 week ago