使用AUTOTRACE 前要做好准备工作

创建角色Plustrace
SQL>        @?/sqlplus/admin/plustrce.sql
将Plustrace角色授于要执行AUTOTRACE的用户
SQL>        grant plustrace to sst;
----------------------------------------------------以上用sys身份执行

设置启用AUTOTRACE
SQL>        set autotrace on(输出结果+执行计划+统计信息)
不显示语句的执行结果
SQL>        set autotrace traceonly(执行计划+统计信息)
只显示执行计划
SQL>        set autotrace traceonly explain(执行计划)

 

 Applies to:
Oracle Server - Enterprise Edition - Version: 10.1.0.5.0
This problem can occur on any platform.
Symptoms:
The issue is that the following error was raised :
ORA-00600: internal error code, arguments: [kesutlGetBindValue-2], [], [], [], [], [], [], []
The recent changes was the :
Migration from 10.1.0.5.0 database control to Grid Control Agent v10.2.0.3.0
What was runing at this moment of the error occurance was :
The attempt to run SQL Tuning Advisor from Grid Control


Cause:
Possibly invalid objects in the database.
As the issue here was to try to use these packages and then failed:
SYS.DBMS_SQLTUNE_INTERNAL
body SYS.PRVT_ADVISOR
body SYS.DBMS_ADVISOR
body SYS.DBMS_SQLTUNE
And as mentioned with the recent changes was the migration.

Solution: