GATE DA 2024 · SQL Queries

NAT · 1 mark · Problem DBMS-SQL-0025

Consider the following two tables named Raider and Team in a relational database maintained by a Kabaddi league. The attribute ID in table Team references the primary key of the Raider table, ID.\[\begin{array}{c} \textbf{Raider} \\ \begin{array}{|l|l|l|l|} \hline ID & Name & Raids & RaidPoints \\ \hline 1 & Arjun & 200 & 250 \\ \hline 2 & Ankush & 190 & 219 \\ \hline 3 & Sunil & 150 & 200 \\ \hline 4 & Reza & 150 & 190 \\ \hline 5 & Pratham & 175 & 220\\ \hline 6 & Gopal & 193 & 215 \\ \hline\end{array} \end{array}\]\[\begin{array}{c} \textbf{Team} \\ \begin{array}{|l|l|l|} \hline City & ID & BidPoints\\ \hline Jaipur & 2 & 200 \\ \hline Patna & 3 & 195 \\ \hline Hyderabad & 5 & 175 \\ \hline Jaipur & 1 & 250 \\ \hline Patna & 4 & 200 \\ \hline Jaipur & 6 & 200 \\ \hline \end{array}\end{array}\]
 The SQL query described below is executed on this database:  SELECT *
FROM Raider, Team
WHERE Raider.ID=Team.ID AND City=“Jaipur” AND
RaidPoints > 200; The number of rows returned by this query is .

Numerical answer (NAT).

Solve it on GATE DA practice →More Relational Model & SQL problems

Show the worked solutionOfficial GATE Answer Key: [3.0, 3.0].See full step-by-step discussion on GateOverflow: https://gateoverflow.in/422941/gate-ds%26ai-2024-question-21

GATE DA practice: past exam problems by chapter, with worked solutions · gatedaprep.com