MCQ IN COMPUTER SCIENCE & ENGINEERING

COMPUTER SCIENCE AND ENGINEERING

SQL

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
Which is the statement which is not correct about Foreign Key?
A
It is a primary key of another table
B
The description of the column should be same
C
There can be multiple foreign keys in a table
D
It supports null values
Explanation: 

Detailed explanation-1: -Q 26-Which of the following is not true about a FOREIGN KEY constraint? A-It is a referential integrity constraint.

Detailed explanation-2: -Foreign keys allow key values that are all NULL, even if there are no matching PRIMARY or UNIQUE keys.

Detailed explanation-3: -The above statement is wrong. A foreign key column must not contain unique values. A FOREIGN KEY constraint can contain null values; however, if any column of a composite FOREIGN KEY constraint contains null values, verification of all values that make up the FOREIGN KEY constraint is skipped.

Detailed explanation-4: -A foreign key may not be null when it is part of a composite primary key in the child table.

There is 1 question to complete.