edited by
2,717 views
2 votes
2 votes

Consider relation ‘R’ and ‘S’ have ‘n’ and ‘m’ tuples, respectively. Choose the best matching between List-I (Expression) and List-II (Maximum number of tuple): 

Soln. According to me Answer should be Option C.

1.R union S = m+n (easy nothing to say)

2.     Say Relations are like:- R(A,B,C)  s(C,D)

               R                                   S

        A     B     C                      C         D

        1      2      3                      3          4

        2     3       3                      3          5

        4     3       3                      3          6

Now in R natual join S = m * n 

So option C should suffice isn't it ?

edited by

3 Answers

0 votes
0 votes

d is Right answer

P- 4 is obvious so no need to explain this. 

Q – 3 because natural join compare the common attribute so the best case would be- all of matches the condition and combine min(m,n) since all tuples are matching extra number of tuples in either of relation will be discarded

R – 2 explanation - because for maximum number of tuple the best case would be – that all tuples in R satisfy the given condition and then got cross product with S and we know that number of tuples in cross product m x n

S – 1 the best case for maximum tuples would be if nothing get minus or discarded from relation R with n tuples so max tuples = n

edited by
0 votes
0 votes
The answer will be option “d”  as the question has asked about the maximum number of tuples.

In option R, if the condition is satisfied by all the tuples of relation R then maximum number can be m*n.

In option Q, the minimum of R,S is found, as first cartesian product is done and then common tuples are shown.
0 votes
0 votes

No correct option.

  1. m + n
  2. m*n because if all tuples of common attribute is same then it will act as Cartesian product
  3. m*n for maximum tuples we assume condition c doesn’t filter any tuples.
  4. n for maximum we assume R has all tuples of L attribute distinct and R and S is disjoint set

Related questions

–1 votes
–1 votes
0 answers
1
Himanshu Kashyap asked Jan 12, 2019
653 views
PLEASE EXPLAIN WHEATHER IT WOULD BE SOME EC DEPARMENT OR ALL EC DEPARTMENT I THINK ALL BECOZ IT IS SELECTION EID OF STUDENT WHO HAVE NOT ENROLLED IN ANY COURSE OF EC
1 votes
1 votes
1 answer
2
nikkey123 asked Jan 29, 2018
1,610 views
Consider the following database tableSupplier (Sid, Sname, rating)Parts (Pid, Pname, color)Catalog (Sid Pid, cost)Which of the following SQL query correct representation ...
0 votes
0 votes
1 answer
4