Posts

Showing posts from October, 2020

ORA-13786 missing SQL text of statement object %s for tuning task %s

While implementing one sql tuning advice from OEM came across following error: ORA-13786 missing SQL text of statement object %s for tuning task %s" when Accepting a SQL Profile for a Parallel Execution Plan In order to identify exact error, query the view dba_advisor_rationale SQL> select message from dba_advisor_rationale where object_id=<object number from error>; MESSAGE -------------------------------------------- This attribute enables parallel execution. The message clearly states it's sql plan enables the parallel execution of query which needs extra attribute in the statement to proceed. In order to re-produce the error on the database run the following commands: EXEC dbms_sqltune.accept_sql_profile(task_name => 'SYS_AUTO_SQL_TUNING_EXAMPLE', object_id => 2); ORA-13786: missing SQL text of statement object "1" for tuning task "SYS_AUTO_SQL_TUNING_EXAMPLE" SQL> select message from dba_advisor_rationale where object_id=2; ME