<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Oracle Outlines &#8211; aka Plan Stability</title>
	<atom:link href="http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/feed/" rel="self" type="application/rss+xml" />
	<link>http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/</link>
	<description>Just another Oracle blog</description>
	<lastBuildDate>Mon, 06 Feb 2012 21:28:20 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
	<item>
		<title>By: Stored Outlines (Plan Stability) are an Enterprise Edition Feature? A Self-Conflicting Story &#171; Charles Hooper&#039;s Oracle Notes</title>
		<link>http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/#comment-75073</link>
		<dc:creator>Stored Outlines (Plan Stability) are an Enterprise Edition Feature? A Self-Conflicting Story &#171; Charles Hooper&#039;s Oracle Notes</dc:creator>
		<pubDate>Fri, 02 Dec 2011 18:33:10 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=742#comment-75073</guid>
		<description>[...] members): http://oracle-randolf.blogspot.com/2009/03/plan-stability-in-10g-using-existing.html http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/ http://www.oracle-base.com/articles/misc/Outlines.php [...]</description>
		<content:encoded><![CDATA[<p>[...] members): <a href="http://oracle-randolf.blogspot.com/2009/03/plan-stability-in-10g-using-existing.html" rel="nofollow">http://oracle-randolf.blogspot.com/2009/03/plan-stability-in-10g-using-existing.html</a> <a href="http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/" rel="nofollow">http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/</a> <a href="http://www.oracle-base.com/articles/misc/Outlines.php" rel="nofollow">http://www.oracle-base.com/articles/misc/Outlines.php</a> [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Outline, SQL profile and SQL Plan Management(SPM) &#171; Oracle Explorer: Standing on the shoulders of giants</title>
		<link>http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/#comment-49143</link>
		<dc:creator>Outline, SQL profile and SQL Plan Management(SPM) &#171; Oracle Explorer: Standing on the shoulders of giants</dc:creator>
		<pubDate>Fri, 22 Jul 2011 00:43:53 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=742#comment-49143</guid>
		<description>[...] Kerry Osborne blog explained more detail about outline http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/ [...]</description>
		<content:encoded><![CDATA[<p>[...] Kerry Osborne blog explained more detail about outline <a href="http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/" rel="nofollow">http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/</a> [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Alibaba DBA Team &#187; 在Oracle 9中伪造存储概要</title>
		<link>http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/#comment-6977</link>
		<dc:creator>Alibaba DBA Team &#187; 在Oracle 9中伪造存储概要</dc:creator>
		<pubDate>Thu, 04 Feb 2010 08:05:45 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=742#comment-6977</guid>
		<description>[...] 关于stored outline还有以下相关资料可以对照阅读下: Oracle Outlines - aka Plan Stability By Kerry Osborne Plan stability in 10g - using existing cursors to create Stored Outlines and SQL [...]</description>
		<content:encoded><![CDATA[<p>[...] 关于stored outline还有以下相关资料可以对照阅读下: Oracle Outlines &#8211; aka Plan Stability By Kerry Osborne Plan stability in 10g &#8211; using existing cursors to create Stored Outlines and SQL [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kerry Osborne&#8217;s Oracle Blog &#187; Blog Archive Oracle 11g SQL Plan Management - SQL Plan Baselines - Kerry Osborne’s Oracle Blog</title>
		<link>http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/#comment-3697</link>
		<dc:creator>Kerry Osborne&#8217;s Oracle Blog &#187; Blog Archive Oracle 11g SQL Plan Management - SQL Plan Baselines - Kerry Osborne’s Oracle Blog</dc:creator>
		<pubDate>Wed, 29 Jul 2009 19:05:08 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=742#comment-3697</guid>
		<description>[...] latest evolution in Oracle&#8217;s efforts to allow a plan to be locked. The previous efforts were Outlines and SQL Profiles. Both of those efforts were based on the idea that hints could be applied to limit [...]</description>
		<content:encoded><![CDATA[<p>[...] latest evolution in Oracle&#8217;s efforts to allow a plan to be locked. The previous efforts were Outlines and SQL Profiles. Both of those efforts were based on the idea that hints could be applied to limit [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kerry Osborne&#8217;s Oracle Blog &#187; Blog Archive SQL Profiles - Kerry Osborne’s Oracle Blog</title>
		<link>http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/#comment-383</link>
		<dc:creator>Kerry Osborne&#8217;s Oracle Blog &#187; Blog Archive SQL Profiles - Kerry Osborne’s Oracle Blog</dc:creator>
		<pubDate>Sun, 05 Apr 2009 03:45:15 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=742#comment-383</guid>
		<description>[...] give credit to Randolf Geist for making me take a second look at SQL Profiles. He commented on my Outlines post last week and recommended I give his post on SQL Profiles a look. I did and it really got me [...]</description>
		<content:encoded><![CDATA[<p>[...] give credit to Randolf Geist for making me take a second look at SQL Profiles. He commented on my Outlines post last week and recommended I give his post on SQL Profiles a look. I did and it really got me [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: osborne</title>
		<link>http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/#comment-332</link>
		<dc:creator>osborne</dc:creator>
		<pubDate>Wed, 01 Apr 2009 21:33:56 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=742#comment-332</guid>
		<description>Excellent post. I had not run across it. I had been thinking about writing something to pull a plan from the awr tables but hadn&#039;t gotten around to it yet. So that will save me some work! 

I do agree with you that SQL Profiles have the advantage of being able to force matching of statements using literals. Outlines, SQL Profiles, and now Baselines all can provide similar functionality, each with their own little twist. I have primarily used SQL Profiles in conjunction with the SQL Tuning Advisor where by SQL Profiles are created based on it&#039;s analysis. These SQL Profiles often make use of the OPT_ESTIMATE hint to scale an estimate for a particular step one direction or the other. These are the hints that make SQL Profiles less attractive to my way of thinking, because these scaling factors stay fixed although the statistics and data in the object can and do change. So a scaling factor that made sense last month may not make any sense this month. That&#039;s why I said that they tend to sour over time. Again, I believe this is specific to using the SQL Tuning Advisor and the SQL Profiles that it generates, so I should probably re-word my post to be a little more clear on that issue. 

I must say, that trying to come up with a set of hints that will only allow the optimizer to choose one plan seems like an approach that is doomed to failure (at least some of the time). That said, the approach has worked pretty well for quite a while, at least on relatively simple queries where the optimizer doesn&#039;t have that many choices to begin with. And it is really the only option prior to 11g. I am working on a post on Baselines now, as I have been able to work with a production 11g system for a while now where we are using them. It will be interesting to see how the hint based mechanism has matured with 11g.

Thanks for your comments and the heads up on your post.

Kerry</description>
		<content:encoded><![CDATA[<p>Excellent post. I had not run across it. I had been thinking about writing something to pull a plan from the awr tables but hadn&#8217;t gotten around to it yet. So that will save me some work! </p>
<p>I do agree with you that SQL Profiles have the advantage of being able to force matching of statements using literals. Outlines, SQL Profiles, and now Baselines all can provide similar functionality, each with their own little twist. I have primarily used SQL Profiles in conjunction with the SQL Tuning Advisor where by SQL Profiles are created based on it&#8217;s analysis. These SQL Profiles often make use of the OPT_ESTIMATE hint to scale an estimate for a particular step one direction or the other. These are the hints that make SQL Profiles less attractive to my way of thinking, because these scaling factors stay fixed although the statistics and data in the object can and do change. So a scaling factor that made sense last month may not make any sense this month. That&#8217;s why I said that they tend to sour over time. Again, I believe this is specific to using the SQL Tuning Advisor and the SQL Profiles that it generates, so I should probably re-word my post to be a little more clear on that issue. </p>
<p>I must say, that trying to come up with a set of hints that will only allow the optimizer to choose one plan seems like an approach that is doomed to failure (at least some of the time). That said, the approach has worked pretty well for quite a while, at least on relatively simple queries where the optimizer doesn&#8217;t have that many choices to begin with. And it is really the only option prior to 11g. I am working on a post on Baselines now, as I have been able to work with a production 11g system for a while now where we are using them. It will be interesting to see how the hint based mechanism has matured with 11g.</p>
<p>Thanks for your comments and the heads up on your post.</p>
<p>Kerry</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Randolf Geist</title>
		<link>http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/#comment-331</link>
		<dc:creator>Randolf Geist</dc:creator>
		<pubDate>Wed, 01 Apr 2009 07:05:07 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=742#comment-331</guid>
		<description>Kerry,

I&#039;ve recently published a blog post where I compare Stored Outlines and SQL Profiles in 10g when attempting to lock down execution plans having the &quot;good&quot; one already in the shared pool (or e.g. AWR, see blog). The method described in my blog post using SQL Profiles offers some additional functionality/flexibility you don&#039;t have with Stored Outlines, so it might be worth a try.

In passing I&#039;ve noticed an odd behaviour of the DBMS_OUTLN.CREATE_OUTLINE procedure in my 10.2.0.4 test runs (apart from the bug in the previous releases) since it didn&#039;t pick up the hints stored along with the plan in the shared pool, but obviously created an outline using the present statistics, which might be irritating.

For more details, see the &lt;a href=&quot;http://oracle-randolf.blogspot.com/2009/03/plan-stability-in-10g-using-existing.html&quot; rel=&quot;nofollow&quot;&gt;blog post&lt;/a&gt;.

Regards,
Randolf

Oracle related stuff blog:
http://oracle-randolf.blogspot.com/

SQLTools++ for Oracle (Open source Oracle GUI for Windows):
http://www.sqltools-plusplus.org:7676/
http://sourceforge.net/projects/sqlt-pp/</description>
		<content:encoded><![CDATA[<p>Kerry,</p>
<p>I&#8217;ve recently published a blog post where I compare Stored Outlines and SQL Profiles in 10g when attempting to lock down execution plans having the &#8220;good&#8221; one already in the shared pool (or e.g. AWR, see blog). The method described in my blog post using SQL Profiles offers some additional functionality/flexibility you don&#8217;t have with Stored Outlines, so it might be worth a try.</p>
<p>In passing I&#8217;ve noticed an odd behaviour of the DBMS_OUTLN.CREATE_OUTLINE procedure in my 10.2.0.4 test runs (apart from the bug in the previous releases) since it didn&#8217;t pick up the hints stored along with the plan in the shared pool, but obviously created an outline using the present statistics, which might be irritating.</p>
<p>For more details, see the <a href="http://oracle-randolf.blogspot.com/2009/03/plan-stability-in-10g-using-existing.html" rel="nofollow">blog post</a>.</p>
<p>Regards,<br />
Randolf</p>
<p>Oracle related stuff blog:<br />
<a href="http://oracle-randolf.blogspot.com/" rel="nofollow">http://oracle-randolf.blogspot.com/</a></p>
<p>SQLTools++ for Oracle (Open source Oracle GUI for Windows):<br />
<a href="http://www.sqltools-plusplus.org:7676/" rel="nofollow">http://www.sqltools-plusplus.org:7676/</a><br />
<a href="http://sourceforge.net/projects/sqlt-pp/" rel="nofollow">http://sourceforge.net/projects/sqlt-pp/</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kerry Osborne&#8217;s Oracle Blog &#187; Blog Archive Bind Variable Peeking - Drives Me Nuts! - Kerry Osborne’s Oracle Blog</title>
		<link>http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/#comment-328</link>
		<dc:creator>Kerry Osborne&#8217;s Oracle Blog &#187; Blog Archive Bind Variable Peeking - Drives Me Nuts! - Kerry Osborne’s Oracle Blog</dc:creator>
		<pubDate>Mon, 30 Mar 2009 22:49:33 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=742#comment-328</guid>
		<description>[...] forcing the optimizer&#8217;s hand such as Outlines (see my previous posts on Unstable Plans and on Outlines). This option provides a quick method of locking in a single plan, but it&#8217;s not fool proof. [...]</description>
		<content:encoded><![CDATA[<p>[...] forcing the optimizer&#8217;s hand such as Outlines (see my previous posts on Unstable Plans and on Outlines). This option provides a quick method of locking in a single plan, but it&#8217;s not fool proof. [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: osborne</title>
		<link>http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/#comment-316</link>
		<dc:creator>osborne</dc:creator>
		<pubDate>Tue, 24 Mar 2009 15:38:39 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=742#comment-316</guid>
		<description>Roberto,

  Sorry for the delay in replying (I&#039;ve been a bit swamped lately). It&#039;s true that outlines don&#039;t always work. The idea is for Oracle to come up with a set of hints that keep the optimizer from doing anything except the current plan. Unfortunately, occasionally there is still room for the optimizer to pick more than one plan. A good example is the new form of the index hint that specifies the table and the column that you want to use an index on (as I mentioned in my previous comment). This hint does not force the use of a single index, it will allow the optimizer to pick any index that contains that combination. So if you have the same column in more than one index, you can get a different plan. Or if you add a new index, the outline might actually pick it up. This is more likely in later releases and obviously in more complicated SQL statements. So as always, testing is important to make sure it&#039;s doing what you want. I do continue to believe that outlines are more stable than SQL profiles. Of course the best way to deal with the issue is to give the optimizer the info it needs using literals where histograms are needed, so we&#039;re really talking about situations where we can&#039;t directly affect the code.

  On a side note, I have created a few outlines in an 11g production environment now, and for simple statements they seem to behave themselves. I am currently experimenting with baselines, as I believe that is a much better approach (actually capturing and saving the execution plan). I hope to write something up on that shortly.

Kerry</description>
		<content:encoded><![CDATA[<p>Roberto,</p>
<p>  Sorry for the delay in replying (I&#8217;ve been a bit swamped lately). It&#8217;s true that outlines don&#8217;t always work. The idea is for Oracle to come up with a set of hints that keep the optimizer from doing anything except the current plan. Unfortunately, occasionally there is still room for the optimizer to pick more than one plan. A good example is the new form of the index hint that specifies the table and the column that you want to use an index on (as I mentioned in my previous comment). This hint does not force the use of a single index, it will allow the optimizer to pick any index that contains that combination. So if you have the same column in more than one index, you can get a different plan. Or if you add a new index, the outline might actually pick it up. This is more likely in later releases and obviously in more complicated SQL statements. So as always, testing is important to make sure it&#8217;s doing what you want. I do continue to believe that outlines are more stable than SQL profiles. Of course the best way to deal with the issue is to give the optimizer the info it needs using literals where histograms are needed, so we&#8217;re really talking about situations where we can&#8217;t directly affect the code.</p>
<p>  On a side note, I have created a few outlines in an 11g production environment now, and for simple statements they seem to behave themselves. I am currently experimenting with baselines, as I believe that is a much better approach (actually capturing and saving the execution plan). I hope to write something up on that shortly.</p>
<p>Kerry</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Roberto</title>
		<link>http://kerryosborne.oracle-guy.com/2008/12/oracle-outlines-aka-plan-stability/#comment-311</link>
		<dc:creator>Roberto</dc:creator>
		<pubDate>Wed, 18 Mar 2009 09:53:42 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=742#comment-311</guid>
		<description>It is not a reproducible case test, however it is not a fake.
I omitted sql profile and outline creations, and the statement, plans, etc., for customer privacy, they are quite complexes.

select plan_hash_value, sql_id, hash_value, child_number, OUTLINE_CATEGORY, SQL_PROFILE
  from v$sql
  where sql_id = &#039;2g985t2xpm0gf&#039;;

 PLAN_HASH_VALUE SQL_ID           HASH_VALUE  CHILD_NUMBER OUTLINE_CATEGORY SQL_PROFILE
---------------- --------------- ----------- ------------- ---------------- -----------
      2269489710 2g985t2xpm0gf    3143205358             0

begin
dbms_sqltune.alter_sql_profile(
  name           =&gt; &#039;to_fix_with_outline&#039;,
  attribute_name =&gt; &#039;status&#039;,
  value          =&gt; &#039;enabled&#039;
);
end;
/

select plan_hash_value, sql_id, hash_value, child_number, OUTLINE_CATEGORY, SQL_PROFILE
  from v$sql
  where sql_id = &#039;2g985t2xpm0gf&#039;;

 PLAN_HASH_VALUE SQL_ID           HASH_VALUE  CHILD_NUMBER OUTLINE_CATEGORY SQL_PROFILE
---------------- --------------- ----------- ------------- ---------------- --------------------
       482806775 2g985t2xpm0gf    3143205358             0                  to_fix_with_outline


alter session set use_stored_outlines = true;

select plan_hash_value, sql_id, hash_value, child_number, OUTLINE_CATEGORY, SQL_PROFILE
  from v$sql
  where sql_id = &#039;2g985t2xpm0gf&#039;;

 PLAN_HASH_VALUE SQL_ID           HASH_VALUE  CHILD_NUMBER OUTLINE_CATEGORY SQL_PROFILE
---------------- --------------- ----------- ------------- ---------------- --------------------
       482806775 2g985t2xpm0gf    3143205358             0                  to_fix_with_outline
      2269489710 2g985t2xpm0gf    3143205358             1 DEFAULT


Since I verified some times the method don&#039;t work, I believed it was a wrong method generally.
But I tried with a artificial case test and it works actually, hence is a possible method.
Can you suggest me any clue because the plan changes?

Best regards,
Roberto</description>
		<content:encoded><![CDATA[<p>It is not a reproducible case test, however it is not a fake.<br />
I omitted sql profile and outline creations, and the statement, plans, etc., for customer privacy, they are quite complexes.</p>
<p>select plan_hash_value, sql_id, hash_value, child_number, OUTLINE_CATEGORY, SQL_PROFILE<br />
  from v$sql<br />
  where sql_id = &#8217;2g985t2xpm0gf&#8217;;</p>
<p> PLAN_HASH_VALUE SQL_ID           HASH_VALUE  CHILD_NUMBER OUTLINE_CATEGORY SQL_PROFILE<br />
&#8212;&#8212;&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212;&#8212; &#8212;&#8212;&#8212;&#8211; &#8212;&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8211;<br />
      2269489710 2g985t2xpm0gf    3143205358             0</p>
<p>begin<br />
dbms_sqltune.alter_sql_profile(<br />
  name           =&gt; &#8216;to_fix_with_outline&#8217;,<br />
  attribute_name =&gt; &#8216;status&#8217;,<br />
  value          =&gt; &#8216;enabled&#8217;<br />
);<br />
end;<br />
/</p>
<p>select plan_hash_value, sql_id, hash_value, child_number, OUTLINE_CATEGORY, SQL_PROFILE<br />
  from v$sql<br />
  where sql_id = &#8217;2g985t2xpm0gf&#8217;;</p>
<p> PLAN_HASH_VALUE SQL_ID           HASH_VALUE  CHILD_NUMBER OUTLINE_CATEGORY SQL_PROFILE<br />
&#8212;&#8212;&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212;&#8212; &#8212;&#8212;&#8212;&#8211; &#8212;&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br />
       482806775 2g985t2xpm0gf    3143205358             0                  to_fix_with_outline</p>
<p>alter session set use_stored_outlines = true;</p>
<p>select plan_hash_value, sql_id, hash_value, child_number, OUTLINE_CATEGORY, SQL_PROFILE<br />
  from v$sql<br />
  where sql_id = &#8217;2g985t2xpm0gf&#8217;;</p>
<p> PLAN_HASH_VALUE SQL_ID           HASH_VALUE  CHILD_NUMBER OUTLINE_CATEGORY SQL_PROFILE<br />
&#8212;&#8212;&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212;&#8212; &#8212;&#8212;&#8212;&#8211; &#8212;&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212;&#8212;- &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br />
       482806775 2g985t2xpm0gf    3143205358             0                  to_fix_with_outline<br />
      2269489710 2g985t2xpm0gf    3143205358             1 DEFAULT</p>
<p>Since I verified some times the method don&#8217;t work, I believed it was a wrong method generally.<br />
But I tried with a artificial case test and it works actually, hence is a possible method.<br />
Can you suggest me any clue because the plan changes?</p>
<p>Best regards,<br />
Roberto</p>
]]></content:encoded>
	</item>
</channel>
</rss>

