Getting Actual Execution Plan in Oracle 11g(在 Oracle 11g 中获取实际执行计划)
问题描述
我已阅读此帖子和这个 优秀文章
I have read this post and this excellent article
我的问题是,如何在 Oracle 11g 中获取实际执行计划
My question is, how to get the acutual execution plan in Oracle 11g
没有 sys 权限和 DBA 权限.(您可以将我的案例视为只读用户)
without sys privilege and DBA privilege. (You can treat my case as a READ-ONLY user)
我可以在 TOAD 中使用 SYS.PLAN_TABLE$ 或 CTRL+E 获得解释计划>
I'm able to get the explain plan using SYS.PLAN_TABLE$ or CTRL+E in TOAD
但我的理解是解释计划=仅估计执行计划?
But my understanding is that explain plan = estimated execution plan only?
在 Oracle 的文档中找到
Found on Oracle's Document
执行计划可能因以下原因而有所不同:
Execution plans can differ due to the following:
-
不同的架构
-
不同的费用
请给我任何你能提供的帮助来澄清我的概念.
Please give me any help you can offer to clear my concepts.
推荐答案
如果你想使用 dbms_xplan.display_cursor,你需要 至少有这些资助:
If you want to use dbms_xplan.display_cursor, you'll need at least these grants:
grant select on sys.v_$sql_plan to larry;
grant select on sys.v_$session to larry;
grant select on sys.v_$sql_plan_statistics_all to larry;
而且您可能还需要 V$SQL 来查找 SQL_ID:
And you'll probably also need V$SQL to find the SQL_ID:
grant select on sys.v_$sql to larry;
这篇关于在 Oracle 11g 中获取实际执行计划的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:在 Oracle 11g 中获取实际执行计划
基础教程推荐
- MySQL 中的类型:BigInt(20) 与 Int(20) 2021-01-01
- 如何在 SQL 中将 Float 转换为 Varchar 2021-01-01
- 如何根据该 XML 中的值更新 SQL 中的 XML 2021-01-01
- oracle区分大小写的原因? 2021-01-01
- mysql选择动态行值作为列名,另一列作为值 2021-01-01
- 什么是 orradiag_<user>文件夹? 2022-01-01
- 表 './mysql/proc' 被标记为崩溃,应该修复 2022-01-01
- 二进制文件到 SQL 数据库 Apache Camel 2021-01-01
- 在 MySQL 中:如何将表名作为存储过程和/或函数参数传递? 2021-01-01
- 在多列上分布任意行 2021-01-01
