The internal exception is raised implicitly whenever your PL/SQL program exceeds a system-dependent limit or violates an Oracle rule. Each & every Oracle error has a number, but exceptions should be handled by the name. Therefore the, PL/SQL predefines some general Oracle errors as exceptions. For illustration, the PL/SQL raises the predefined exception NO_DATA_FOUND when a SELECT INTO statement returns no rows.
You can use the OTHERS handler, to handle the other Oracle errors. The SQLCODE & SQLERRM functions are primarily very helpful in the OTHERS handler since they return the message text & the Oracle error code. Otherwise, you can use the pragma EXCEPTION_INIT to relate an exception names with the Oracle error codes.
The PL/SQL declares predefined exceptions globally in the package STANDARD that defines the PL/SQL atmosphere. Therefore, you need not declare them yourself. You can write the handlers for predefined exceptions using the names shown in the list below. The corresponding Oracle error codes and SQLCODE return values are also shown.
A short description of the predefined exceptions is as shown below: