Computer Science
Assertion. There is no restriction on the number of columns that can have PRIMARY KEY constraint or UNIQUE constraints.
Reason. There can be multiple columns with UNIQUE constraint but PRIMARY KEY constraint can be defined only once for one or more columns.
DDL & DML
1 Like
Answer
(d)
Assertion is false but Reason is true.
Explanation
There can exist multiple columns with UNIQUE constraints in a table, but there can exist only one column or one combination with PRIMARY KEY constraint.
Answered By
2 Likes
Related Questions
Assertion. The PRIMARY KEY and UNIQUE constraints are the same.
Reason. The columns with PRIMARY KEY or UNIQUE constraints have unique values for each row.
Assertion. The treatment of NULL values is different with PRIMARY KEY and UNIQUE constraints.
Reason. The column(s) with PRIMARY KEY do not allow the NULL value even in a single row but UNIQUE constraint allows NULL for one of the rows.
Assertion. There are different commands for creating and changing table design.
Reason. The CREATE TABLE command creates the tables while ALTER TABLE command changes the design of an existing table.
Assertion. Both DELETE and DROP TABLE carry out the same thing — deletion in tables.
Reason. The DELETE command deletes the rows and DROP TABLE deletes the whole table.