A relation \( r(A,B) \) has 1200 tuples.
Attribute \( A \) ranges from 6 to 20 and attribute \( B \) ranges from 1 to 20. Assume independent uniform distribution. The estimated number of tuples in \( \sigma_{(A>10)\vee(B=18)}(r) \) is \(\underline{\hspace{2cm}}\).
Step 1: Given probabilities.
P(A > 10) = 10 / 15
P(B = 18) = 1 / 20
Step 2: Apply probability formula.
Assuming independence between attributes A and B:
P((A > 10) ∨ (B = 18)) = P(A > 10) + P(B = 18) − P(A > 10)P(B = 18)
Step 3: Substitute values.
= (10 / 15) + (1 / 20) − (10 / 15)(1 / 20)
= 0.6667 + 0.05 − 0.0333
= 0.6834
Step 4: Estimate number of tuples.
Total number of tuples = 1200
Estimated tuples = 1200 × 0.6834 ≈ 820
Final Answer:
820
Consider the following three relations in a relational database.
Employee(\(eId\), Name), Brand(\(bId\), bName), Own(\(eId\), \(bId\))
Which of the following relational algebra expressions return the set of \(eId\)'s who own all the brands?