<?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"
	>
<channel>
	<title>Comments on: Flush A Single SQL Statement</title>
	<atom:link href="http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/feed/" rel="self" type="application/rss+xml" />
	<link>http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/</link>
	<description>Just another Oracle blog</description>
	<pubDate>Thu, 29 Jul 2010 12:01:04 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.3</generator>
		<item>
		<title>By: Eric Cloutier</title>
		<link>http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/#comment-12273</link>
		<dc:creator>Eric Cloutier</dc:creator>
		<pubDate>Tue, 15 Jun 2010 19:12:19 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=114#comment-12273</guid>
		<description>Thank you for your blog.</description>
		<content:encoded><![CDATA[<p>Thank you for your blog.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: osborne</title>
		<link>http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/#comment-7369</link>
		<dc:creator>osborne</dc:creator>
		<pubDate>Mon, 15 Feb 2010 17:09:54 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=114#comment-7369</guid>
		<description>Thanks David. 

You're exactly right. There is another script that gets run by dbmspool.sql (prvtpool.plb). 

I see the "Package body created." message in a previous comment, but at any rate I just re-ran it. Here's the output I got:

SQL&gt; @dbmspool

Package created.


Grant succeeded.


View created.


Package body created.</description>
		<content:encoded><![CDATA[<p>Thanks David. </p>
<p>You&#8217;re exactly right. There is another script that gets run by dbmspool.sql (prvtpool.plb). </p>
<p>I see the &#8220;Package body created.&#8221; message in a previous comment, but at any rate I just re-ran it. Here&#8217;s the output I got:</p>
<p>SQL> @dbmspool</p>
<p>Package created.</p>
<p>Grant succeeded.</p>
<p>View created.</p>
<p>Package body created.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: David Fitzjarrell</title>
		<link>http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/#comment-7368</link>
		<dc:creator>David Fitzjarrell</dc:creator>
		<pubDate>Mon, 15 Feb 2010 16:53:37 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=114#comment-7368</guid>
		<description>The script dbmspool11g.sql only creates the package specification, not the body, and it does invalidate the current package body because it doesn't match the current spec.  Look inside the script and you'll find only a CREATE OR REPLACE PACKAGE ... command; there will also be a .plb file in the same location which will create the package body to match the specification.  The ?/rdbms/admin/dbmspool.sql script which Kerry used creates the package spec and calls the wrapped script to create the corresponding package body.  All I see in your posted output is 'Package created.'; there should also be the following messge:

"Package body created."

for this to function correctly.

If you can't find a corresponding .plb file for the dbmspool11g.sql script I suggest you run the listed dbmspool.sql script to get the spec and body created correctly.</description>
		<content:encoded><![CDATA[<p>The script dbmspool11g.sql only creates the package specification, not the body, and it does invalidate the current package body because it doesn&#8217;t match the current spec.  Look inside the script and you&#8217;ll find only a CREATE OR REPLACE PACKAGE &#8230; command; there will also be a .plb file in the same location which will create the package body to match the specification.  The ?/rdbms/admin/dbmspool.sql script which Kerry used creates the package spec and calls the wrapped script to create the corresponding package body.  All I see in your posted output is &#8216;Package created.&#8217;; there should also be the following messge:</p>
<p>&#8220;Package body created.&#8221;</p>
<p>for this to function correctly.</p>
<p>If you can&#8217;t find a corresponding .plb file for the dbmspool11g.sql script I suggest you run the listed dbmspool.sql script to get the spec and body created correctly.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: osborne</title>
		<link>http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/#comment-7299</link>
		<dc:creator>osborne</dc:creator>
		<pubDate>Sat, 13 Feb 2010 16:15:55 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=114#comment-7299</guid>
		<description>No, I haven't run into that problem. Sorry. The file that I executed was called called dbmspool.sql (the back ported version) not dbmspool11g.sql. Might try checking with support or the other "trick" way using the create outline, drop outline method I talked about here: 

http://kerryosborne.oracle-guy.com/2008/12/flush-a-single-sql-statement-take-2/. 

(although that method is a bit flaky due to using Outlines)

Kerry</description>
		<content:encoded><![CDATA[<p>No, I haven&#8217;t run into that problem. Sorry. The file that I executed was called called dbmspool.sql (the back ported version) not dbmspool11g.sql. Might try checking with support or the other &#8220;trick&#8221; way using the create outline, drop outline method I talked about here: </p>
<p><a href="http://kerryosborne.oracle-guy.com/2008/12/flush-a-single-sql-statement-take-2/"  rel="nofollow">http://kerryosborne.oracle-guy.com/2008/12/flush-a-single-sql-statement-take-2/</a>. </p>
<p>(although that method is a bit flaky due to using Outlines)</p>
<p>Kerry</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: JMIZE</title>
		<link>http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/#comment-7249</link>
		<dc:creator>JMIZE</dc:creator>
		<pubDate>Thu, 11 Feb 2010 16:11:29 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=114#comment-7249</guid>
		<description>Kerry - has anyone ever indicated that the pbod for dbms_shared_pool becomes invalidated with the 10.2.0.4.0 patch or 11g dbmspool.sql is loaded? I came upon your post during a production issue we are having with bad plans on peeked binds. This seems like the perfect solution if I could get it to work. I have recreated this both on HPUX and Linux. 

sys@BKUP&#62; @dbmspool11g.sql

Package created.


Grant succeeded.

sys@BKUP&#62; exec dbms_shared_pool.purge('0000000181E6C1F0,3606220645', 'C', 1);
BEGIN dbms_shared_pool.purge('0000000181E6C1F0,3606220645', 'C', 1); END;

*
ERROR at line 1:
ORA-04063: package body "SYS.DBMS_SHARED_POOL" has errors
ORA-06508: PL/SQL: could not find program unit being called: "SYS.DBMS_SHARED_POOL"
ORA-06512: at line 1</description>
		<content:encoded><![CDATA[<p>Kerry - has anyone ever indicated that the pbod for dbms_shared_pool becomes invalidated with the 10.2.0.4.0 patch or 11g dbmspool.sql is loaded? I came upon your post during a production issue we are having with bad plans on peeked binds. This seems like the perfect solution if I could get it to work. I have recreated this both on HPUX and Linux. </p>
<p>sys@BKUP&gt; @dbmspool11g.sql</p>
<p>Package created.</p>
<p>Grant succeeded.</p>
<p>sys@BKUP&gt; exec dbms_shared_pool.purge(&#8217;0000000181E6C1F0,3606220645&#8242;, &#8216;C&#8217;, 1);<br />
BEGIN dbms_shared_pool.purge(&#8217;0000000181E6C1F0,3606220645&#8242;, &#8216;C&#8217;, 1); END;</p>
<p>*<br />
ERROR at line 1:<br />
ORA-04063: package body &#8220;SYS.DBMS_SHARED_POOL&#8221; has errors<br />
ORA-06508: PL/SQL: could not find program unit being called: &#8220;SYS.DBMS_SHARED_POOL&#8221;<br />
ORA-06512: at line 1</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: How to invalidate execution plan &#171; Coskan&#8217;s Approach to Oracle</title>
		<link>http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/#comment-5919</link>
		<dc:creator>How to invalidate execution plan &#171; Coskan&#8217;s Approach to Oracle</dc:creator>
		<pubDate>Sat, 12 Dec 2009 14:36:42 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=114#comment-5919</guid>
		<description>[...] http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/    Comments (3) [...]</description>
		<content:encoded><![CDATA[<p>[...] <a href="http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/"  rel="nofollow">http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/</a>    Comments (3) [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: osborne</title>
		<link>http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/#comment-4171</link>
		<dc:creator>osborne</dc:creator>
		<pubDate>Tue, 18 Aug 2009 13:48:50 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=114#comment-4171</guid>
		<description>I just realized that in some instances, the upgrade from 10.2.0.3 to 10.2.0.4 does not automatically create the DBMS_SHARED_POOL package. The file $ORACLE_HOME/rdbms/admin/dbmspool.sql should be there. But you may need to execute it manually to create the package. Like so:


&#62; cd $ORACLE_HOME/rdbms/admin

[homer:osborne:LAB1024] /u01/app/oracle/product/lab1024/10.2.0/rdbms/admin 
&#62; !sql
sqlplus / as sysdba

SQL*Plus: Release 10.2.0.4.0 - Production on Tue Aug 18 08:32:54 2009

Copyright (c) 1982, 2007, Oracle.  All Rights Reserved.


Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options

SQL&#62; @dbmspool

Package created.


Grant succeeded.


View created.


Package body created.



Kerry</description>
		<content:encoded><![CDATA[<p>I just realized that in some instances, the upgrade from 10.2.0.3 to 10.2.0.4 does not automatically create the DBMS_SHARED_POOL package. The file $ORACLE_HOME/rdbms/admin/dbmspool.sql should be there. But you may need to execute it manually to create the package. Like so:</p>
<p>&gt; cd $ORACLE_HOME/rdbms/admin</p>
<p>[homer:osborne:LAB1024] /u01/app/oracle/product/lab1024/10.2.0/rdbms/admin<br />
&gt; !sql<br />
sqlplus / as sysdba</p>
<p>SQL*Plus: Release 10.2.0.4.0 - Production on Tue Aug 18 08:32:54 2009</p>
<p>Copyright (c) 1982, 2007, Oracle.  All Rights Reserved.</p>
<p>Connected to:<br />
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - Production<br />
With the Partitioning, OLAP, Data Mining and Real Application Testing options</p>
<p>SQL&gt; @dbmspool</p>
<p>Package created.</p>
<p>Grant succeeded.</p>
<p>View created.</p>
<p>Package body created.</p>
<p>Kerry</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kerry Osborne&#8217;s Oracle Blog &#38;raquo; Blog Archive I&#8217;ll Gladly Pay You Tuesday for a Hamburger Today - Kerry Osborne’s Oracle Blog</title>
		<link>http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/#comment-1855</link>
		<dc:creator>Kerry Osborne&#8217;s Oracle Blog &#38;raquo; Blog Archive I&#8217;ll Gladly Pay You Tuesday for a Hamburger Today - Kerry Osborne’s Oracle Blog</dc:creator>
		<pubDate>Thu, 21 May 2009 00:30:29 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=114#comment-1855</guid>
		<description>[...] In 11g this is very easy as there is a built function (psuedo documented) to flush a single SQL statement from the shared pool (see my previous post - Flush A Single SQL Statement - for details).  [...]</description>
		<content:encoded><![CDATA[<p>[...] In 11g this is very easy as there is a built function (psuedo documented) to flush a single SQL statement from the shared pool (see my previous post - Flush A Single SQL Statement - for details).  [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kerry Osborne&#8217;s Oracle Blog &#187; Blog Archive Flush a Single SQL Statement - Take 2 - Kerry Osborne’s Oracle Blog</title>
		<link>http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/#comment-67</link>
		<dc:creator>Kerry Osborne&#8217;s Oracle Blog &#187; Blog Archive Flush a Single SQL Statement - Take 2 - Kerry Osborne’s Oracle Blog</dc:creator>
		<pubDate>Fri, 12 Dec 2008 17:34:23 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=114#comment-67</guid>
		<description>[...] posted earlier about the ability to flush a single SQL statement out of the shared pool in 11g (also back ported to 10.2.0.4 with a bit .... If you are on an earlier release of Oracle though, you can accomplish the same thing by creating [...]</description>
		<content:encoded><![CDATA[<p>[...] posted earlier about the ability to flush a single SQL statement out of the shared pool in 11g (also back ported to 10.2.0.4 with a bit &#8230;. If you are on an earlier release of Oracle though, you can accomplish the same thing by creating [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: osborne</title>
		<link>http://kerryosborne.oracle-guy.com/2008/09/flush-a-single-sql-statement/#comment-3</link>
		<dc:creator>osborne</dc:creator>
		<pubDate>Thu, 02 Oct 2008 19:49:53 +0000</pubDate>
		<guid isPermaLink="false">http://kerryosborne.oracle-guy.com/?p=114#comment-3</guid>
		<description>I assume you mean the flush_sql.sql script. It is actually linked in the text in the post. I'm still experimenting with wrapping examples with that source code widget thing. Here's the source in case you can't get it the link to work.

set serveroutput on
set pagesize 9999
set linesize 155
var name varchar2(50)
accept sql_id -
       prompt 'Enter value for sql_id: '

BEGIN

select address&#124;&#124;','&#124;&#124;hash_value into :name
from v$sqlarea
where sql_id like '&#038;&#038;sql_id';

dbms_shared_pool.purge(:name,'C',1);

END;
/

undef sql_id
undef name</description>
		<content:encoded><![CDATA[<p>I assume you mean the flush_sql.sql script. It is actually linked in the text in the post. I&#8217;m still experimenting with wrapping examples with that source code widget thing. Here&#8217;s the source in case you can&#8217;t get it the link to work.</p>
<p>set serveroutput on<br />
set pagesize 9999<br />
set linesize 155<br />
var name varchar2(50)<br />
accept sql_id -<br />
       prompt &#8216;Enter value for sql_id: &#8216;</p>
<p>BEGIN</p>
<p>select address||&#8217;,'||hash_value into :name<br />
from v$sqlarea<br />
where sql_id like &#8216;&#038;&#038;sql_id&#8217;;</p>
<p>dbms_shared_pool.purge(:name,&#8217;C',1);</p>
<p>END;<br />
/</p>
<p>undef sql_id<br />
undef name</p>
]]></content:encoded>
	</item>
</channel>
</rss>
