1,863 views

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 ?

Some detail must be missing in the question. None of the options is absolutely correct.
Well sir this is the question and it's complete :)
Sir is C option incorrect. And sir why u think that question is incomplete?
Yeah its correct answer is C.
Option c is right.
@ abhishekmehta4u in option (R). suppose given condition pass all the elements of R then cross product with S will be n×m not min of (n,m) .right??
@na462 like the example u took abve

if in R option i put condition as c=3 than your all tuples selected now you are doing cross product with S, so here max tuples possible would be m*n so none of the option is fully correct
Please explain how R would imply 2.
In Realtion R we have n tuples and S we have m tuples

we apply section condition on Relation R in such a way that all 'n' tuples in Relation R is satisfy

then we just  do cartesian product of RXS

therefore  max number of tuples we got : m X n
I think it has to be R×S.

And then selection is applied on resultant table.
Q is also  2
No Q is given as min(m,n)
Join is Cartesian product followed by selection then in case all tuples satisfy selection condition then maximum size becomes m×n.

Verma Ashish yes right !!

Magma i have one doubt- your first comment implies that (R) is correct.

But it seems to be invalid i never see cross product on selection codition..it is perfectly valid if it is projection..because result of projection is also a relation..

Correct me if I'm wrong .

see the ( ) on Relation R

ist it just execute selection condition on R then it does cartesian product

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

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.
by

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

–1 vote