Which of the following is not constraint in SQL?

2023

Which of the following is not constraint in SQL?

  1. A.

    Primary key

  2. B.

    Not null

  3. C.

    Union

  4. D.

    More than one of the above

  5. E.

    None of the above

Attempted by 1479 students.

Show answer & explanation

Correct answer: C

In SQL, constraints are used to enforce rules on data in a table. Common constraints include PRIMARY KEY, NOT NULL, UNIQUE, FOREIGN KEY, and CHECK. PRIMARY KEY ensures that each row in a table is uniquely identified and that the column does not contain NULL values. NOT NULL constraint ensures that a column cannot have NULL values, thus maintaining data integrity. UNION is not a constraint; it is a SQL operator used to combine the results of two or more SELECT statements into a single result set. Therefore, among the given options, UNION is not a constraint in SQL.

Explore the full course: Up Lt Grade Assistant Teacher 2025