Stored Outline is replaced by SPM in 11g. Stored Outline is valid only pre 11g version.
If cursor_sharing=FORCE then outline is disabled.
Stored outlines can be generated for a single
statement or at the session or the instance level
ALTER SESSION set create_stored_outlines = {TRUE|category|FALSE}
ALTER SYSTEM set create_stored_outlines = {TRUE|category|FALSE} [NOOVERRIDE]
CREATE OUTLINE outline [FOR CATEGORY category] ON statement
Exporting Oulines
===============
EXP OUTLN/outln_password FILE=exp-file TABLES= 'OL$' 'OL$HINTS' 'OL$NODES'
QUERY='WHERE CATEGORY="problemcat"'
A Stored Outline will only be used when the parameter USE_STORED_OUTLINES is set persistently. If parameter is set using alter session or by defining in pfile/spfile the change is not permanent and will no longer be set after database has been restarted.
A STARTUP trigger needs to be defined in order to make this setting persistent after restart of database
Solution
Create the following trigger to be run on startup of the database:
create or replace trigger enable_outlines_trig
after startup on database
begin
execute immediate('alter system set use_stored_outlines=true');
end;
No comments:
Post a Comment