admin 管理员组

文章数量: 1184232


2024年3月13日发(作者:数据结构知识点总结pdf)

预定义异常

命名的系统异常

ACCESS_INTO_NULL

CASE_NOT_FOUND

COLLECTION_IS_NULL

CURSER_ALREADY_OPEN

DUP_VAL_ON_INDEX

INVALID_CURSOR

INVALID_NUMBER

NO_DATA_FOUND

TOO_MANY_ROWS

ZERO_DIVIDE

SUBSCRIPT_BEYOND_COUNT

SUBSCRIPT_OUTSIDE_LIMIT

VALUE_ERROR

LOGIN_DENIED

NOT_LOGGED_ON

PROGRAM_ERROR

ROWTYPE_MISMATCH

SELF_IS_NULL

STORAGE_ERROR

SYS_INVALID_ID

TIMEOUT_ON_RESOURCE

产生原因

未定义对象

CASE 中若未包含相应的 WHEN ,并且没有设置 ELSE 时

集合元素未初始化

游标已经打开

唯一索引对应的列上有重复的值

在不合法的游标上进行操作

内嵌的 SQL 语句不能将字符转换为数字

使用 select into 未返回行,或应用索引表未初始化的元素时

执行 select into 时,结果集超过一行

除数为 0

元素下标超过嵌套表或 VARRAY 的最大值

使用嵌套表或 VARRAY 时,将下标指定为负数

赋值时,变量长度不足以容纳实际数据

PL/SQL 应用程序连接到 oracle 数据库时,提供了不正确的用户名或密

PL/SQL 应用程序在没有连接 oralce 数据库的情况下访问数据

PL/SQL 内部问题,可能需要重装数据字典& pl./SQL 系统包

宿主游标变量与 PL/SQL 游标变量的返回类型不兼容

使用对象类型时,在 null 对象上调用对象方法

运行 PL/SQL 时,超出内存空间

无效的 ROWID 字符串

Oracle 在等待资源时超时

预定义异常

Oracle异常名称

错误号

说明

DUP_VAL_ON_INDEX

ORA-00001

You tried to execute an INSERT or UPDATE statement that has created a duplicate value in a

field restricted by a unique index.试图破坏一个唯一性限制

TIMEOUT_ON_RESOURCE

ORA-00051

You were waiting for a resource and you timed out.在等待资源时发生超时

TRANSACTION_BACKED_OUT

ORA-00061

The remote portion of a transaction has rolled back.由于发生死锁事务被撤消

INVALID_CURSOR

ORA-01001

You tried to reference a cursor that does not yet exist. This may have happened because you’ve

executed a FETCH cursor or CLOSE cursor before OPENing the cursor.试图使用一个未打开的

游标

NOT_LOGGED_ON

ORA-01012

You tried to execute a call to Oracle before logging in.没有连接到ORACLE

LOGIN_DENIED

ORA-01017

You tried to log into Oracle with an invalid username/password combination.无效的用户名/口

NO_DATA_FOUND

ORA-01403

SELECT INTO没有找到数据You tried one of the following:

You executed a SELECT INTO statement and no rows were referenced an

uninitialized row in a read past the end of file with the UTL_FILE package.

TOO_MANY_ROWS

ORA-01422

SELECT INTO 返回多行You tried to execute a SELECT INTO statement and more than one

row was returned.

ZERO_DIVIDE

ORA-01476

试图被零除You tried to divide a number by zero.

INVALID_NUMBER

ORA-01722

转换一个数字失败You tried to execute an SQL statement that tried to convert a string to a

number, but it was unsuccessful.

STORAGE_ERROR

ORA-06500

内存不够或内存被破坏引发的内部错误You ran out of memory or memory was corrupted.

PROGRAM_ERROR

ORA-06501

内部错误,需重新安装数据字典视图和pl/sql包This is a generic “Contact Oracle support”

message because an internal problem was encountered.


本文标签: 数据 游标 对象 变量 下标