This preview has intentionally blurred sections. Sign up to view the full version.
View Full DocumentThis preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
Unformatted text preview: CS4604 Final Examination December 11, 2006 Please enter the following information: Name: ID: GOOD LUCK! Please do not write below this line. Question Maximum Score Score 1 30 2 7 3 11 4 12 5 20 6 20 7 * 20 Total 100 * Extra credit 1 1. (3 × 10 = 30 points) (a) If relation R has n tuples and relation S has m tuples, what is the maximum number of tuples that R ∩ S can contain? Assume settheoretic semantics. (b) An E/R diagram has three entity sets A , B , and C . It also contains three relationships: R between A and B ; S between B and C ; and T between C and A . The relationships do not contain any attributes. Which of the relationships is redundant, i.e., the tuples contained in it can be inferred from the tuples in the other two relationships? (c) The scenario is the same as in the previous question. In addition, you know that each relationship is oneone. Which relationships are redundant? (d) How many nontrivial multivalued dependencies are possible in a two attribute relation? (e) What is the difference between “ DROP R; ” and “ DELETE FROM R; ”? (f) When is an attributebased CHECK constraint checked by an RDBMS? (g) Rewrite σ C ( R × S ) as another expression in relational algebra. (h) A relation R has attributes A , B , and C . Fill in the blank so that the query returns each tuple in R exactly once. SELECT * FROM R ; (i) Circle true or false . The result of the query (SELECT ProfessorPID FROM Teach) EXCEPT (SELECT PID FROM Professors) ; can contain the same tuple more than once. (j) Who lives in a pineapple under the sea? 2 2. (3 + 4 = 7 points) Suppose a relation R has attributes A 1 ,A 2 ,...,A n . As a function of n , how many superkeys does R have if (a) R has exactly one key made up of two attributes { A 1 ,A 2 } ....
View
Full
Document
This note was uploaded on 12/24/2011 for the course CS 4604 taught by Professor Cmmalik during the Fall '08 term at Virginia Tech.
 Fall '08
 CMMALIK

Click to edit the document details