暂无图片
分享
卢春龙
2019-07-25
历史快照可以看到 analyze table 可是根据SQLID在dba_hist_sqltext找不到为什么呢?

image.png


收藏
分享
3条回答
默认
最新
卢春龙

历史快照可以看到 analyze table 可是根据SQLID在dba_hist_sqltext找不到为什么呢?


暂无图片 评论
暂无图片 有用 0
lastwinner

1、时间等限制条件去掉

2、不是所有在HIST_ASH里有SQL_ID的,都会一定有SQL Text。dba_hist_sqltext里存在的SQL_ID,在DBA_HIST_SQLSTAT里一定能找到。所以你可以拿SQL_id直接在DBA_HIST_SQLSTAT里找,如果没有,那就是hist里没有保存该SQL的信息。

ps:建议仔细理解下面这段话。

DBA_HIST_SQLSTAT displays historical information about SQL statistics. This view captures the top SQL statements based on a set of criteria and captures the statistics information from V$SQL.

暂无图片 评论
暂无图片 有用 0
卢春龙
问题已关闭: 问题已经得到解决
暂无图片 评论
暂无图片 有用 0
回答交流
提交
问题信息
请登录之后查看
邀请回答
暂无人订阅该标签,敬请期待~~
暂无图片墨值悬赏