Skip to Main Content

Enterprise Manager

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

ORA-13780 when running SQL tuning advisor, and solution

Searching for "ORA-13780: SQL statement does not exist" when running SQL tuning advisor I found
SQL tuning Advisor for old statements (0 Bytes)But the thread has been closed so I can't post a comment there. In addition to what the response said in the thread, I want to add that if you can reproduce the execution plan for the SQL, you can run the tuning advisor. So, get the SQL text and try to run it in sqlplus or any tool. If there're bind variables, substitute actual values (you may find them in v$sql_bind_capture). The SQL you run doesn't have to be exactly the same as the one you can't run tuning advisor on. As long as the hash value of the plan for your SQL matches that for the SQL you can't get advisor info on (you can get its hash value from v$sqlarea or v$sqlstats, the latter retaining info longer), then you run the SQL tuning advisor on the SQL you just ran. If you're advised e.g. creating an index, do so and both SQLs (your sqlplus SQL and the one you can't get advisor info on) will benefit.

Comments
Post Details
Added on Nov 22 2022
0 comments
406 views