Let R be a relation with schema (A_1, A_2, ..., A_n, B_1, B_2, ..., B_m) and let S be a relation with schema (B_1, B_2, ..., B_m); so that the attributes of S are a subset of the attributes of R. The quotient of R and S: denoted R S, is the st of tuples t over attributes A_1, A_2, ..., A_n such that for every tuple s in S, the tuple ts: consisting of the components of t for A_1, A_2, ..., A_n and the components of s for B_1, B_2, ..., B_m, is a member of R. Give an expression of relational algebra, using the operators we have defined before in this section, that is equivalent to R S. Another algebraic way to express a constraint is E_1 = E_2. where both E_1 and E_2 are relational-algebra expressions. Can this form of constraint express more than two forms ? Suppose R is a relation with attributes A_1, A-2, ..., A_n As a function of n, tell how many superkeys R has, if: The only key is A1. Suppose R is a relation with attributes A_1, A_2, ..., A_n As a function of n, tell how many superkeys R has. if: The only keys are (A1, A2) and {A3, A4} Suppose R is a relation with attributes A_1, A_2, ..., A_n As a function of n, tell how many superkeys R has, if: The only keys are (A1, A2) and {A1, A3} Prove that {X^+}Z = {X}^+
Q3) supose R is a relation with attributes A1,A2,.......An
as a function of n,tell how many superkeys R has, if The only key is A1.
Answer:-
By first checking that the closure of A1, A2, ..., An (i.e. { A1, A2, ..., An}+ is all attributes of the relation R, and then checking that no subset of A1, A2, ..., An is all attributes of R.
Q4) supose R is a relation with attributes A1,A2,.......An
as a function of n,tell how many superkeys R has, if The only key are (A1,A2) and {A3,A4}.
Answer:-
Number of combinations of attributes that contains {A1}, {A2} or {A3,A4}: 3 * 2^{n-2} .
Q5) supose R is a relation with attributes A1,A2,.......An
as a function of n,tell how many superkeys R has, if The only key are (A1,A2) and {A1,A3}.
Answer:-
Number of combinations of attributes that contains {A1}, {A2} or {A1,A3}: 3 * 2^{n-1}