1. Trang chủ
  2. » Giáo án - Bài giảng

cơ sở dữ liệu lê thị bảo thu exercises 5 concurrency control techniques sinhvienzone com

2 92 0

Đang tải... (xem toàn văn)

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 2
Dung lượng 303,65 KB

Nội dung

DBMS – HK1 2016-2017 Exercises – Chapter Exercises (Course: Database Management Systems) Chapter Concurrency Control Techniques Consider the schedule shown in the following figure Draw the wait-for graph before and after the last action write_lock(A) of transaction T3 T1 T2 T3 T4 read_lock(A) read_item(A) write_lock(B) write_item(B) read_lock(B) read_lock(C) read_item(C) write_lock( C) write_lock(B) write_lock(A) Consider the set of transactions accessing database element A shown in the following figure These transactions are operating under an ordinary timestamp-based scheduler Explain why the transaction T3 has to be aborted What happens if these transactions are operating under a multiversion timestamp-based scheduler? (Note: In the figure r means read and w means write.) T1 T2 T3 T4 A 150 200 175 225 RT=0 WT=0 r1(A) RT=150 Khoa Khoa học & Kỹ thuật Máy tính – Đại học Bách Khoa TP.HCM CuuDuongThanCong.com https://fb.com/tailieudientucntt DBMS – HK1 2016-2017 Exercises – Chapter w1(A) WT=150 r2(A) RT=200 w2(A) WT=200 r3(A) Abort r4(A) RT=225 Consider the relation Movie(title, year, length, studioName) Transaction T1 consists of the query: SELECT * FROM Movie WHERE title = ‘King Kong’ Transaction T2 consists of the query: UPDATE Movie SET year = 1939 WHERE title = ‘Gone with the wind’ Assume that there are two records in relation Movie with the title ‘King Kong’ and there is one record with the title ‘Gone with the wind’ Suggest the collection of locks for this situation (Multiple Granularity Locking) Khoa Khoa học & Kỹ thuật Máy tính – Đại học Bách Khoa TP.HCM CuuDuongThanCong.com https://fb.com/tailieudientucntt ...DBMS – HK1 2016-2017 Exercises – Chapter w1(A) WT= 150 r2(A) RT=200 w2(A) WT=200 r3(A) Abort r4(A) RT=2 25 Consider the relation Movie(title, year, length, studioName)... situation (Multiple Granularity Locking) Khoa Khoa học & Kỹ thu t Máy tính – Đại học Bách Khoa TP.HCM CuuDuongThanCong .com https://fb .com/ tailieudientucntt

Ngày đăng: 29/01/2020, 14:41

TỪ KHÓA LIÊN QUAN

w