Which of the following is not a valid Oracle PL/SQL exception.

  1. NO_DATA_FOUND ORA-01403

  2. DUP_VAL_ON_INDEX ORA-00001

  3. TWO_MANY_ROWS ORA-01422

  4. OTHERS

  5. None of the above. These are all valid.


Correct Option: C
Explanation:

To solve this question, the user needs to have knowledge of Oracle PL/SQL exceptions and their syntax.

The correct answer is option C. TWO_MANY_ROWS ORA-01422 is not a valid Oracle PL/SQL exception.

Explanation for each option:

A. NO_DATA_FOUND ORA-01403: This is a valid exception in Oracle PL/SQL. It is raised when a SELECT INTO statement returns no rows.

B. DUP_VAL_ON_INDEX ORA-00001: This is a valid exception in Oracle PL/SQL. It is raised when a unique index constraint is violated.

C. TWO_MANY_ROWS ORA-01422: This is not a valid exception in Oracle PL/SQL. It is an invalid exception.

D. OTHERS: This is a valid exception in Oracle PL/SQL. It is used to catch any exception that is not explicitly handled.

E. None of the above. These are all valid: This option is incorrect as option C is not a valid exception.

Therefore, the answer is: C.

Find more quizzes: