Class - 12 CBSE Computer Science — Assertion Reason Type Questions
Assertion. The PRIMARY KEY and FOREIGN KEY constraints are similar.
Reason. The FOREIGN KEY constraint links a column of a table with the PRIMARY KEY constraint of another table.
- Both A and R are true and R is the correct explanation of A.
- Both A and R are true but R is not the correct explanation of A.
- A is true but R is false.
- A is false but R is true.
SQL Queries
1 Like
Answer
Both A and R are true but R is not the correct explanation of A.
Explanation
The PRIMARY KEY and FOREIGN KEY constraints are similar in that they both deal with unique identifiers. However, they serve different purposes, PRIMARY KEY uniquely identifies each record in a table while FOREIGN KEY establishes a relationship between two tables by linking a column (or set of columns) to the PRIMARY KEY of another table.
Answered By
1 Like