Oracle之sql追踪

select * from v$sqlarea t where t.sql_text like  '%_070%' order by t.LAST_ACTIVE_TIME desc
SELECT * FROM  v$session  st where st.SQL_ID='gabpcbzqjx0vc'

select t.hash_value,t.address from v$sqlarea t where t.sql_id  in ('gabpcbzqjx0vc','7bj040na7ky72')  order by t.LAST_ACTIVE_TIME desc
select b.server,b.username,b.sid,b.machine,b.*  FROM v$session b  WHERE b.SQL_ADDRESS='07000004A0F81A50'

07000004A0F81A50
070000050ACE5DC8

SELECT * FROM  v$active_session_history   t where  t.sql_id  in ('gabpcbzqjx0vc','7bj040na7ky72') 
select object_owner,object_name from dba_hist_sql_plan where sql_id='7bj040na7ky72';
SELECT * FROM v$active_session_history   t where  t.sql_id  in ('gabpcbzqjx0vc','7bj040na7ky72') 
select parsing_schema_id,parsing_schema_name,t.*  from dba_hist_sqlstat t where t.sql_id  in ('gabpcbzqjx0vc','7bj040na7ky72') 
SELECT * FROM DBA_HIST_ACTIVE_SESS_HISTORY t   where t.sql_id  in ('gabpcbzqjx0vc','7bj040na7ky72')
posted @ 2015-09-30 09:53  轮子手  阅读(448)  评论(0编辑  收藏  举报