For which two constraints does the Oracle Server implicitly create a unique index? (Choose two.)

  1. NOT NULL

  2. PRIMARY KEY

  3. FOREIGN KEY

  4. CHECK

  5. UNIQUE KEY


Correct Option: B,E

AI Explanation

To answer this question, we need to understand the different types of constraints in a database and how they relate to the creation of unique indexes.

Option A) NOT NULL - The NOT NULL constraint ensures that a column cannot have a NULL value. However, it does not implicitly create a unique index. Therefore, this option is incorrect.

Option B) PRIMARY KEY - The PRIMARY KEY constraint uniquely identifies each record in a table. When a primary key constraint is defined on a column or a combination of columns, the Oracle Server implicitly creates a unique index on those columns. This is because a primary key must be unique and enforce entity integrity. Therefore, this option is correct.

Option C) FOREIGN KEY - The FOREIGN KEY constraint establishes a relationship between two tables, where the values in one table must match the values in another table's primary key or unique key. However, this constraint does not implicitly create a unique index. Therefore, this option is incorrect.

Option D) CHECK - The CHECK constraint is used to limit the values that can be placed in a column. It does not implicitly create a unique index. Therefore, this option is incorrect.

Option E) UNIQUE KEY - The UNIQUE KEY constraint ensures that all values in a column or a combination of columns are unique. When a unique key constraint is defined on a column or a combination of columns, the Oracle Server implicitly creates a unique index on those columns. This is because a unique key must enforce uniqueness. Therefore, this option is correct.

The correct answers are B) PRIMARY KEY and E) UNIQUE KEY. These constraints result in the Oracle Server implicitly creating a unique index to enforce uniqueness and entity integrity.

Find more quizzes: