日期:2014-05-17 浏览次数:20834 次
SELECT *
FROM (SELECT b.username username,
a.disk_reads
/ DECODE (a.executions, 0, 1, a.executions) rds_exec_ratio,
a.sql_text STATEMENT
FROM v$sqlarea a, dba_users b
WHERE a.parsing_user_id = b.user_id AND b.username = 'DEVHXYW'
ORDER BY rds_exec_ratio DESC)
WHERE STATEMENT LIKE 'SELECT comcname,comcode FROM prpdcompany where%' AND ROWNUM < 11
ORDER BY rds_exec_ratio DESC
select sql_text,operation_type,policy,(last_memory_used/1024/1024),
last_execution,last_tempseg_size
from v$sql i,v$sql_workarea a
where i.hash_value=a.hash_value
and sql_text LIKE 'SELECT comcname,comcode FROM prpdcompany where%'