Which type of integrity constraint ensures that a foreign key value must either match an existing primary key value in the parent table or be NULL? MCQ with Answer and Explanation

Which type of integrity constraint ensures that a foreign key value must either match an existing primary key value in the parent table or be NULL?
A. Referential Integrity
B. Entity Integrity
C. Domain Integrity
D. Key Integrity
Answer: Option A
Solution (By JKSSB Mock Tests)
Referential Integrity ensures that relationships between tables remain consistent, requiring a foreign key to point to a valid existing row in the referenced table.

Discuss this Question (0)

No comments yet. Be the first to start the discussion!

Practice More Database Management System (DBMS) Questions

Question #1
Which SQL function returns the average of a numeric column?
A. COUNT()
B. AVG()
C. SUM()
D. MEAN()

Correct Answer: Option B


Explanation:
AVG() calculates the average of the values in a numeric column.

This question belongs to: Computer Database Management System (DBMS)
Question #2
Which of the following is a valid SQL statement to add a new column to a table?
A. ADD COLUMN TO table_name column_name datatype;
B. Both A and C
C. ALTER TABLE table_name ADD column_name datatype;
D. ALTER TABLE table_name ADD COLUMN column_name datatype;

Correct Answer: Option B


Explanation:
Both 'ADD column_name datatype' and 'ADD COLUMN column_name datatype' are valid syntax in some DBMS, but standard SQL uses 'ADD column_name datatype'. However, many DBMS support both.

This question belongs to: Computer Database Management System (DBMS)
Question #3
What is a candidate key?
A. A set of columns that uniquely identifies a row and can serve as a primary key
B. A column that allows duplicate values
C. A foreign key
D. A column that can be used as a primary key but is not chosen

Correct Answer: Option A


Explanation:
A candidate key is an attribute or set of attributes that can uniquely identify a tuple; one is selected as the primary key.

This question belongs to: Computer Database Management System (DBMS)