Skip to main contentSkip to solution

Primary key is a combination of which of the following constraints?

(A) Unique

(B) Distinct

(C) Not Null

(D) Default

Solution

✅ Correct Option: 1

A primary key uniquely identifies each row and cannot be empty. So it combines the UNIQUE constraint (no duplicate values) with the NOT NULL constraint (no missing values).


Option 2: DISTINCT is a keyword used in SELECT queries to remove duplicate rows from results, not a constraint.

Options 3 and 4: DEFAULT only supplies a value when none is given, so it plays no part in a primary key.

A table can have only one primary key, but it can have several UNIQUE columns, and UNIQUE alone allows NULL values.

Keyboard Shortcuts

  • Left arrow: Previous question
  • Right arrow: Next question
  • S key: Jump to solution
  • Q key: Jump to question