René Nyffenegger's collection of things on the web
René Nyffenegger on Oracle - Most wanted - Feedback
 

dbms_xplan

As of 9i, this package formats the contents of the plan table

Procedures/Functions

display

function display returns dbms_xplan_type_table (
 table_name                         in                 varchar2 default,
 statement_id                       in                 varchar2 default,
 format                             in                 varchar2 default,
 filter_preds                       in                 varchar2 default
);
It seems as though display chooses the rows with the highest plan_id in the plan_table to display a plan.

display_awr

function display_awr returns dbms_xplan_type_table (
 sql_id                             in                 varchar2        ,
 plan_hash_value                    in               number(38) default,
 db_id                              in               number(38) default,
 format                             in                 varchar2 default
);

display_cursor

function display_cursor returns dbms_xplan_type_table (
 sql_id                             in                 varchar2 default,
 cursor_child_no                    in               number(38) default,
 format                             in                 varchar2 default
);

display_sqlset

function display_sqlset returns dbms_xplan_type_table (
 sqlset_name                        in                 varchar2        ,
 sql_id                             in                 varchar2        ,
 plan_hash_value                    in               number(38) default,
 format                             in                 varchar2 default,
 sqlset_owner                       in                 varchar2 default
);

prepare_records

function prepare_records returns dbms_xplan_type_table (
 plan_cur                       cursor                      ref      in,
 i_format_flags                     in           binary_integer        
);

validate_format

function validate_format returns boolean (
 hasplanstats                       in                  boolean        ,
 format                             in                 varchar2        ,
 format_flags                      out           binary_integer        
);