To flush a sql or purge a sql from shared pool you need to find out the sql_id you are trying to purge..
Once you get the id
run the following command
select address, hash_value from v$sqlarea where sql_id like '8ktqrp3vwp51w';
Once you get the id
run the following command
select address, hash_value from v$sqlarea where sql_id like '8ktqrp3vwp51w';
This will give you address and hash_value of the sql
Now insert these values in the following query and execute
exec dbms_shared_pool.purge('0000000B6ECC55E8, 2891302865','C');
Some times when you execute above you will get the following error
*
ERROR at line 1:
ORA-06550: line 1, column 7:
PLS-00201: identifier 'DBMS_SHARED_POOL.PURGE' must be declared
ORA-06550: line 1, column 7:
PL/SQL: Statement ignored
ERROR at line 1:
ORA-06550: line 1, column 7:
PLS-00201: identifier 'DBMS_SHARED_POOL.PURGE' must be declared
ORA-06550: line 1, column 7:
PL/SQL: Statement ignored
If this is the case
Goto $ORACLE_HOME/rdbms/admin
sqlplus / as sysdba
@dbmspool.sql
After this run the exec command again and this should fix the issue..
You can also flush the entire shared pool using the following command
alter system flush shared_pool;
No comments:
Post a Comment