While developing Oracle applications you may come across any number of error codes. The following PLSQL code can generate the appropriate error message for a given range of error codes and raised exceptions.
BEGIN
-- Generate range of error messages
FOR error_num IN 1000..1010 LOOP
dbms_output.put_line(SQLERRM(-error_num));
END LOOP;
END;
ORA-01000: maximum open cursors exceeded
ORA-01001: invalid cursor
ORA-01002: fetch out of sequence
ORA-01003: no statement parsed
ORA-01004: default username feature not supported; logon denied
ORA-01005: null password given; logon denied
ORA-01006: bind variable does not exist
ORA-01007: variable not in select list
ORA-01008: not all variables bound
ORA-01009: missing mandatory parameter
ORA-01010: invalid OCI operation