Question
Consider the following two relations, and :
| R.A | R.B |
|---|---|
| 10 | 20 |
| 20 | 30 |
| 30 | 40 |
| 30 | 50 |
| 50 | 95 |
| S.A | S.C |
|---|---|
| 10 | 90 |
| 30 | 45 |
| 40 | 80 |
The total number of tuples obtained by evaluating the following expression
is _________
Official answer and solution
- Official answer
- 2
- From
- Official GATE 2024 answer key
Solution
First compute the equijoin and then filter the resulting tuples using the condition .
- Equijoin :
Matching tuples where (which occurs for and ) gives tuples: - Selection :
- For : holds selected.
- For : holds selected.
- For : is false discarded.
Thus, a total of 2 tuples are obtained.
Final answer
2
The answer is the one in the official GATE answer key. The solution is this site's own explanation.
Source
- Paper
- GATE 2024 Computer Science and Information Technology - Set 1 (CS1)
- Question
- 35 of 65
- Section
- Computer Science and Information Technology
Report an error in this question
GATE questions are the work of the organising institutes. This site is independent and is not affiliated with them.