Oracle 视图 DBA_OUTLINE_HINTS 官方解释,作用,如何使用详细说明
本站中文解释
Oracle视图DBA_OUTLINE_HINTS提供了有关当前轮廓的详细信息,可以帮助用户学习如何使用外部轮廓。外部轮廓使Oracle数据库在解释执行SQL语句时提供提示,以改善执行时间。它们还可以用于避免因查询重写失败而导致出现更慢的执行计划。
可以使用DBA_OUTLINE_HINTS视图来生成Hint文件,然后将其标记为可用,以便在外部轮廓组SQL语句执行时使用。要生成外部轮廓,您必须使用CREATE_OUTLINE_FILE存储过程,该存储过程使用DBA_OUTLINE_HINTS视图的结果作为输入。下面是使用DBA_OUTLINE_HINTS视图的一个示例:
EXECUTE DBMS_OUTLINE_MANAGER.CREATE_OUTLINE_FILE(
outline_name => ’emp_create_outline’,
source_cursor => ‘select * from emp where job = ”CLERK”;’,
source_desc => DBMS_UTILITY.MAKE_DESCR(23),
outline_hints => DBMS_OUTLINE_MANAGER.DBA_OUTLINE_HINTS);
官方英文解释
DBA_OUTLINE_HINTS
describes the set of hints stored in all outlines in the database.
Related View
USER_OUTLINE_HINTS
describes the set of hints stored in the outlines owned by the current user. This view does not display the OWNER
column.
Column | Datatype | NULL | Description |
---|---|---|---|
|
|
Name of the outline |
|
|
|
Name of the user who created the outline |
|
|
|
ID of the query or subquery to which the hint applies. The top-level query is labeled |
|
|
|
Outline hints can be applied at three different stages during the compilation process. This column indicates the stage at which this hint was applied. |
|
|
|
Position of the table in the join order. The value is |
|
|
|
Text of the hint |
See Also:
“USER_OUTLINE_HINTS”