procedure to create a customized ERROR message

  1. RAISE_ERROR

  2. SQLERRM

  3. RAISE_APPLICATION_ERROR

  4. RAISE_SERVER_ERROR


Correct Option: C

AI Explanation

To create a customized error message in Oracle PL/SQL, you can use the RAISE_APPLICATION_ERROR procedure.

The correct answer is C) RAISE_APPLICATION_ERROR.

Explanation:

Option A) RAISE_ERROR - This option is incorrect because there is no built-in procedure called RAISE_ERROR.

Option B) SQLERRM - This option is incorrect because SQLERRM is a function that returns the error message associated with the most recently raised error. It does not allow you to create a customized error message.

Option C) RAISE_APPLICATION_ERROR - This option is correct because the RAISE_APPLICATION_ERROR procedure allows you to raise a user-defined exception and specify a customized error message along with an error code. You can use this procedure to create a customized error message.

Option D) RAISE_SERVER_ERROR - This option is incorrect because there is no built-in procedure called RAISE_SERVER_ERROR in Oracle PL/SQL.

Therefore, the correct answer is C) RAISE_APPLICATION_ERROR.

Find more quizzes: