 |
|
Oracle Tips by Burleson |
Altering an OUTLINE
Outlines are altered using the ALTER OUTLINE
or CREATE OR REPLACE form of the CREATE command. The format of the
command is identical whether it is used for initial creation or
replacement of an existing outline. For example, what if we want to
add SUM (b.blocks) to the previous example?
CREATE OR
REPLACE OUTLINE get_tables
ON
SELECT
a.owner,
a.table_name,
a.tablespace_name,
SUM(b.bytes),
COUNT(b.table_name) extents,
SUM(b.blocks)
FROM
dba_tables a,
dba_extents b
WHERE...
See code depot
This is an excerpt by
Mike Ault’s e-book:
Using Oracle SQL Stored Outlines & Optimizer Plan Stability
ISBN:
0-9740716-8-4
http://www.rampant-books.com/ebook_plan_stability.htm
|