[Question 3] We have a database with a buffer size of 12 buffers and two tables, R and S, with
following properties:
:
R: 100,000 pages and 10,000,000 tuples total
S: 2,000 pages and 200,000 tuples total
Compute the total I/O cost and total time cost (at 0.1 ms/IO) of the following join algorithms on R
and S.
a. Naïve Nested Loop Join with R as outer table and S as inner table (6 points).
b. Naïve Nested Loop Join with S as outer table and R as inner table (6 points).
c. Block Nested Loop with S as outer table and R as inner table (6 points).
d. Sort-Merge Join (2 point).
Which of the above join algorithms should be preferred for joining the tables R and S (6 points)?