Databases Reference
In-Depth Information
3.
Edit the private outline and update it:
EXEC DBMS_OUTLN_EDIT.REFRESH_PRIVATE_OUTLINE(
'PVT_CUST_LIST_OUTLINE');
4.
Use the private outline and test it:
ALTER SESSION SET USE_PRIVATE_OUTLINES = TRUE;
5. Publish the modified outline back to the public stored outlines:
CREATE OR REPLACE OUTLINE CUST_LIST_OUTLINE
FROM PRIVATE PVT_CUST_LIST_OUTLINE;
6.
Disable private outlines and drop the corresponding tables:
ALTER SESSION SET USE_PRIVATE_OUTLINES = FALSE;
EXEC DBMS_OUTLN_EDIT.DROP_EDIT_TABLES;
See also
F The Exploring the optimizer hints and Configuring and using SQL Baselines
recipes in this chapter
Introducing Adaptive Cursor Sharing for
bind variable peeking
In the previous chapter, we have explored the (recommended) use of bind variables.
In this recipe, we will see how using bind variables can be disadvantageous in certain
situations and learn about a feature of Oracle Database 11 g that helps us with this.
How to do it...
The following steps will demonstrate Adaptive Cursor Sharing:
1.
Connect to SH schema:
CONNECT sh@TESTDB/sh
2. Create a table for testing with a field ID that equals 1:
CREATE TABLE sh.MY_TEST AS SELECT
OBJECT_NAME AS NAME, 1 AS ID
FROM ALL_OBJECTS NOLOGGING;
 
Search WWH ::




Custom Search