zoukankan      html  css  js  c++  java
  • 索引 碎片查看

     DBCC SHOWCONTIG (ep_ProdCardToRollbase)--ep_ProdCardToRollbase表名
    输出:
    DBCC SHOWCONTIG scanning 'ep_ProdCardToRollBase' table...
    Table: 'ep_ProdCardToRollBase' (581433691); index ID: 1, database ID: 21
    TABLE level scan performed.
    - Pages Scanned................................: 43
    - Extents Scanned..............................: 6
    - Extent Switches..............................: 5
    - Avg. Pages per Extent........................: 7.2
    - Scan Density [Best Count:Actual Count].......: 100.00% [6:6]
    - Logical Scan Fragmentation ..................: 0.00%
    - Extent Scan Fragmentation ...................: 0.00%
    - Avg. Bytes Free per Page.....................: 1533.9
    - Avg. Page Density (full).....................: 81.05%  密度越低,说明碎片越多
    DBCC execution completed. If DBCC printed error messages, contact your system administrator.
    

      

    创建非聚集索引:
    CREATE NONCLUSTERED INDEX [ndx_for_cascaderelationship_ep_ep_card_ep_prodcardtoroll_ProductionOrderCardNo] ON [dbo].[ep_ProdCardToRollBase]
    (
        [ep_ProductionOrderCardNo] ASC
    )
    WHERE ([ep_ProductionOrderCardNo] IS NOT NULL)
    WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, SORT_IN_TEMPDB = OFF, DROP_EXISTING = OFF, ONLINE = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, FILLFACTOR = 80) ON [PRIMARY]
    GO
  • 相关阅读:
    【案例】ora600
    Oracle 10046 event
    Oracle redo与undo浅析
    BUFFER CACHE和SHARED POOL原理
    oracle体系结构基础
    Oracle-buffer cache、shared pool
    获取oracle数据库对象定义
    ORA-20011
    expdp/impdp中NETWORK_LINK参数使用
    day03-Python基础
  • 原文地址:https://www.cnblogs.com/tiancaige/p/14403516.html
Copyright © 2011-2022 走看看