时间:2021-07-01 10:21:17 帮助过:4人阅读
管理自动sql调优任务
1.开启自动sql调优
begin dbms_auto_task_admin.enable( client_name => ‘sql tuning advisor‘, operation => ‘NULL‘,#在所有维护窗口都开启 window_name => ‘NULL‘); end;
2.关闭自动sql调优
begin dbms_auto_task_admin.disable( client_name => ‘sql tuning advisor‘, operation => ‘NULL‘, window_name => ‘NULL‘); end;
生成文本格式的自动sql调优建议报告:
SQL> variable my_rept CLOB; SQL> begin :my_rept := dbms_sqltune.report_auto_tuning_task( begin_exec=>NULL, end_exec=>NULL, type=>‘TEXT‘, level=> ‘TYPICAL‘, section=>‘ALL‘, object_id=>NULL, result_limit=>NULL); end; SQL> print :my_rept
相关视图:
-DBA_ADVISOR_EXECUTIONS
11g新特性-自动sql调优(Automatic SQL Tuning)
标签: