Which constraint ensures that every value in a specific column is unique across all rows in that table, but still permits a NULL value? MCQ with Answer and Explanation

Which constraint ensures that every value in a specific column is unique across all rows in that table, but still permits a NULL value?
A. UNIQUE
B. FOREIGN KEY
C. PRIMARY KEY
D. CHECK
Answer: Option A
Solution (By JKSSB Mock Tests)
The UNIQUE constraint prevents duplicate entries in a column. Unlike a Primary Key, a UNIQUE constraint typically allows one or more rows to store NULL values depending on the database engine.

Discuss this Question (0)

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

Practice More Database Management System (DBMS) Questions

Question #1
What is a primary key in a database table?
A. A key that uniquely identifies each row in a table
B. A key that can contain duplicate values
C. A key that references a column in another table
D. A key that is always numeric

Correct Answer: Option A


Explanation:
A primary key is a column or set of columns that uniquely identifies each row in a table, ensuring entity integrity.

This question belongs to: Computer Database Management System (DBMS)
Question #2
What does the EXISTS operator do in SQL?
A. Tests for the existence of rows returned by a subquery
B. Checks if a value is null
C. Compares two values
D. Performs arithmetic

Correct Answer: Option A


Explanation:
EXISTS returns TRUE if the subquery returns at least one row, otherwise FALSE.

This question belongs to: Computer Database Management System (DBMS)
Question #3
What does the letter 'D' stand for in the widely accepted ACID properties of database transactions?
A. Data
B. Dependency
C. Durability
D. Definition

Correct Answer: Option C


Explanation:
ACID stands for Atomicity, Consistency, Isolation, and Durability. Durability ensures that once a transaction commits, its changes survive system failures.

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