ORA-16959: Statement type has been disabled for SQL Analyze

文档解释

ORA-16959: Statement type has been disabled for SQL Analyze

Cause: The system attempted to analyze a type of statement that was disabled by the current feature.

Action: Try a different feature capable of analyzing this statement type.

## 解释

ORA-16959表明SQL Analyze功能为指定的语句类型已经被禁用,例如CREATE TABLE。

## 官方解释

ORA-16959表明SQL Analyze工具已经被禁用,无法再支持分析所指定的语句类型。

常见案例

如果某个SQL语句被指定为要被Analyze分析,但是Analyze工具不支持这个类型的SQL语句,那么会抛出ORA-16959错误。

## 正常处理方法及步骤

要解决ORA-16959错误,需要:

1. 使用sqlplus登录数据库,查看当前已启动的可用SQL Analyze语句类型:

“`

SELECT validity, statement_type

FROM resource_view

WHERE resource_name = ‘sql_analyze’;

“`

2. 若要支持需要分析的SQL语句类型,添加以下参数以启用它们:

“`

ALTER SYSTEM SET RESOURCE_LIMIT = TRUE statement_type=’XXXX’;

“`

3. 重新分析SQL语句,即可解决ORA-16959问题

你可能感兴趣的