Test Index

CBSE Class 12 Computer Science 2025 Paper Set 4 Get it on Google PlayDownload on the App Store

© examsnet.com
Question : 21 of 37
Marks: +1, -0
Assertion (A): We can retrieve records from more than one table in MYSQL.
Reason (R): Foreign key is used to establish a relationship between two tables.
Solution:  
Explanation:
Assertion: true. A SELECT can name several tables (Cartesian product, equi-join, natural join), e.g.
SELECT S.NAME, C.CNAME FROM STUDENT S, COURSE C
WHERE S.CID = C.CID;
Reason: true. A foreign key in one table refers to the primary key of another table and so links (relates) the two tables.
But the reason does not explain the assertion: records can be fetched from several tables whether or not a foreign key is defined (a Cartesian product or a join on any matching columns works without one). A foreign key is about referential integrity, not about how a query reads several tables.
Key point: Joins need common values, not a declared foreign key; so both statements are true but R is not the correct explanation of A.
Answer:
Option B (Both Assertion (A) and Reason (R) are true and Reason (R) is not the correct explanation for Assertion (A).)
© examsnet.com
Advertisements
Go to Question: