Oracle 中查看比較大的排序進程

來源:互聯網
上載者:User

  1. sys@DEX> select * from v$statname where name like '%sort%' ;  
  2.   
  3. STATISTIC# NAME                                          CLASS    STAT_ID  
  4. ---------- ---------------------------------------- ---------- ----------   
  5.        565 sorts (memory)                                   64 2091983730  
  6.        566 sorts (disk)                                     64 2533123502  
  7.        567 sorts (rows)                                     64 3757672740  
這裡使用rows作為metric 
  1. sys@DEX> select s.sid "session id", st.value "sort(rows)" ,p.spid "process number"  
  2.   2    from v$session s , v$sesstat st , v$process p  
  3.   3   where s.sid=st.sid  
  4.   4     and s.paddr=p.addr  
  5.   5     and st.statistic#=567  
  6.   6     and s.username='DEX'  
  7.   7     order by st.value desc ;  
  8.   
  9.   
  10. session id sort(rows) process number  
  11. ---------- ---------- ------------------------------------------------------------------------   
  12.         30    1818678 2223  
  13.        155     909404 5573  

相關文章

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.