CS计算机代考程序代写 COMP9315 Sample Exam

COMP9315 Sample Exam

COMP9315 Sample Exam

The University of New South Wales

COMP9315 DBMS Implementation
Sample Exam

DBMS Implementation

[Instructions] [Notes] [PostgreSQL] [C]

[Q1] [Q2] [Q3] [Q4] [Q5] [Q6] [Q7] [Q8]

Question 7 (10 marks)

Consider two relations R(id,x,y) and S(rid,a,b,c),
with bR = 100
and bS = 500, and a join operation on these two tables:

select * from R join S on (R.id = S.rid)

Assume that each R tuple joins with exactly one S tuple,
and that any hash functions used distribute the tuples uniformly.

Ignoring the cost of writing the final output (the joined tuples), describe
how each of the following joins would occur and calculate the number of reads
and writes that would occur in evaluating them:

using simple hash join with 10 memory buffers

using hybrid hash join with 20 memory buffers, and holding one bucket of R in memory

Show all working.

Instructions:

Type your answer to this question into the file called q7.txt

Submit via:   give cs9315 sample_q7 q7.txt

or via: Webcms3 > exams > Sample Exam > Submit Q7 > Make Submission

End of Question