Oracle 视图 V$RULE_SET 官方解释,作用,如何使用详细说明

本站中文解释

Oracle 视图 V$RULE_SET 表示 Oracle 数据库实例中定义的所有规则集(Rulesets)的一个总结。用户可以查看每个规则集的属性,以及规则集所对应的数据库对象,以及规则集所包含的规则。

V$RULE_SET 视图中的用户可以查询的信息包括:规则集的核心属性(是否可用,执行深度,上次更新时间等)以及规则集支持的数据库对象和规则。

使用 Oracle 视图 V$RULE_SET 要点:

1. 在查询视图时,记得必须对视图许可权进行连接,以获得查询结果。

2. 查看某个特定的规则集的所有属性,只需将规则集的名称放入 WHERE 子句中,即可查询出该规则集的信息,例如:

SELECT * FROM V$RULE_SET WHERE RULESET_NAME = ‘MyRuleSet’;

3. 查看某个特定规则集所支持的数据库对象,只需将规则集的名称和对象名称放入 V$RULE_SET_OBJECT 表中,即可查询出该规则集所支持的对象,例如:

SELECT OBJECT_NAME FROM V$RULE_SET_OBJECT WHERE RULESET_NAME = ‘MyRuleSet’;

4. 查看某个特定规则集所包含的规则,只需将规则集的名称和规则名称放入 V$RULE_SET_RULE 表中,即可查询出该规则集包含的规则,例如:

SELECT RULE_NAME FROM V$RULE_SET_RULE WHERE RULESET_NAME = ‘MyRuleSet’;

官方英文解释

V$RULE_SET displays rule set statistics. This view has a row for every rule set loaded into shared memory.

Note:

Querying the V$RULE_SET view may have a negative impact on performance if a database has a large library cache.

Column Datatype Description

OWNER

VARCHAR2(128)

Owner of the rule set

NAME

VARCHAR2(128)

Name of the rule set

CPU_TIME

NUMBER

Total CPU time (in hundredths of a second) spent in evaluation of the rule set

ELAPSED_TIME

NUMBER

Total elapsed time (in hundredths of a second) spent in evaluation of the rule set

FIRST_LOAD_TIME

DATE

First time the current cached copy of the rule set was loaded

LAST_LOAD_TIME

DATE

Last time the current cached copy of the rule set was loaded

LAST_LOADING_TIME

NUMBER

Total elapsed time (in hundredths of a second) spent to load the rule set the last time it was loaded

SHARABLE_MEM

NUMBER

Shared memory (in bytes) used by the rule set

RELOADS

NUMBER

Number of times the rule set object was reloaded in shared memory

INVALIDATIONS

NUMBER

Number of times the rule set object was invalidated

EVALUATIONS

NUMBER

Number of evaluations on the rule set

FIRST_HIT_EVALUATIONS

NUMBER

Number of evaluations on the rule set, with stop_on_first_hit set to TRUE

SIMPLE_RULES_ONLY_EVALUATIONS

NUMBER

Number of evaluations on the rule set, with simple_rules_only set to TRUE

SQL_FREE_EVALUATIONS

NUMBER

Number of evaluations on the rule set which did not internally issue SQL to evaluate rules

SQL_EXECUTIONS

NUMBER

Total number of SQL statements executed during evaluation of the rule set

CONDITIONS_PROCESSED

NUMBER

Total number of fast (indexed) conditions processed during evaluation of the rule set

TRUE_RULES

NUMBER

Total number of TRUE rules returned during evaluation of the rule set

MAYBE_RULES

NUMBER

Total number of MAYBE rules returned during evaluation of the rule set

VARIABLE_VALUE_FUNCTION_CALLS

NUMBER

Total number of calls made to user-defined functions to retrieve variable values (specified by the variable_value_function field in RE$VARIABLE_TYPE) made during evaluation of the rule set

VARIABLE_METHOD_FUNCTION_CALLS

NUMBER

Total number of calls made to user-defined functions to retrieve variable method values (specified by the variable_method_function field in RE$VARIABLE_TYPE) made during evaluation of the rule set

EVALUATION_FUNCTION_CALLS

NUMBER

Total number of calls made to user-defined evaluation functions (specified as the evaluation_function argument to the DBMS_RULE_ADM.CREATE_EVALUATION_CONTEXT procedure) made during evaluation of the rule set

RESULT_CACHE_HITS

NUMBER

Number of result cache hits across all the sessions evaluating this rule set

IS_RESULT_CACHE

VARCHAR2(3)

Indicates whether this rule set result can be cached (YES) or not (NO)

RESULT_CACHE_ELEMENTS

NUMBER

Number of elements cached within the result cache

CON_ID

NUMBER

The ID of the container to which the data pertains. Possible values include:

  • 0: This value is used for rows containing data that pertain to the entire CDB. This value is also used for rows in non-CDBs.

  • 1: This value is used for rows containing data that pertain to only the root

  • n: Where n is the applicable container ID for the rows containing data

See Also:

Oracle Database PL/SQL
Packages and Types Reference
for more information about the DBMS_RULE_ADM.CREATE_EVALUATION_CONTEXT procedure


数据运维技术 » Oracle 视图 V$RULE_SET 官方解释,作用,如何使用详细说明