zoukankan      html  css  js  c++  java
  • 查看带有A-Time的执行计划

    先执行

    SQL> alter session set statistics_level=all;
    
    会话已更改。

    再执行SQL语句:

    SQL> select count(*) from tb_16million;
    
      COUNT(*)
    ----------
      16000000

    再查看带有A-time的执行计划:

    SQL> select * from table(dbms_xplan.display_cursor(null,null,'allstats last'));
    
    PLAN_TABLE_OUTPUT
    ----------------------------------------------------------------------------------------------------------
    SQL_ID  8k8dgbz5g9cta, child number 0
    -------------------------------------
    select count(*) from tb_16million
    
    Plan hash value: 685847080
    
    ------------------------------------------------------------------------------------------------------------
    | Id  | Operation             | Name            | Starts | E-Rows | A-Rows |   A-Time   | Buffers | Reads  |
    ------------------------------------------------------------------------------------------------------------
    |   0 | SELECT STATEMENT      |                 |      1 |        |      1 |00:00:02.44 |   35573 |   1707 |
    |   1 |  SORT AGGREGATE       |                 |      1 |      1 |      1 |00:00:02.44 |   35573 |   1707 |
    
    PLAN_TABLE_OUTPUT
    -----------------------------------------------------------------------------------------------------------
    |   2 |   INDEX FAST FULL SCAN| TB_16MILLION_PK |      1 |     16M|     16M|00:00:01.77 |   35573 |   1707 |
    ------------------------------------------------------------------------------------------------------------
    
    
    已选择14行。
    
    SQL>
  • 相关阅读:
    Fix The System Bell
    Autounlock default keyring during login KDE
    打油诗1
    Give your laptop some gaming power
    ubuntu 12.04 wine安装有道词典
    天津工业大学破烂综合教务系统非IE非Windows解决方案
    愤忿,愤,忿
    C Strings (Arrays vs. Pointers)
    深入学习算法的一点拙见
    jquery控制图片按比例缩放
  • 原文地址:https://www.cnblogs.com/heyang78/p/12554993.html
Copyright © 2011-2022 走看看