激情久久久_欧美视频区_成人av免费_不卡视频一二三区_欧美精品在欧美一区二区少妇_欧美一区二区三区的

服務器之家:專注于服務器技術及軟件下載分享
分類導航

Mysql|Sql Server|Oracle|Redis|MongoDB|PostgreSQL|Sqlite|DB2|mariadb|Access|數據庫技術|

服務器之家 - 數據庫 - Oracle - Oracle中檢查是否需要重構索引的sql

Oracle中檢查是否需要重構索引的sql

2019-11-29 17:43Oracle教程網 Oracle

經常需要在Oracle中檢查是否需要重構索引,在此寫了個示例語句,有此需求的朋友可以參考下,希望對大家有所幫助

代碼如下:


SELECT 
height, /*Height of the B-Tree*/ 
blocks, /* Blocks in the index segment */ 
name, /*index name */ 
lf_rows, /* number of leaf rows in the index */ 
lf_blks, /* number of leaf blocks in the index */ 
del_lf_rows, /* number of deleted leaf rows in the index */ 
rows_per_key /* average number of rows per distinct key */ 
blk_gets_per_access /* consistent mode block reads (gets) */ 
FROM INDEX_STATS 
WHERE NAME='INDEX_NAME'; 

 

復制代碼代碼如下:


ANALYZE index INDEX_NAME VALIDATE STRUCTURE 



HEIGHT: 
This column refers to the height of the B-tree index, and it's usually at the 1, 2, or 3 level. 
If large inserts push the index height beyond a level of 4, it's time to rebuild, which flattens the B-tree. 

DEL_LF_ROWS: 
This is the number of leaf nodes deleted due to the deletion of rows. 
Oracle doesn't rebuild indexes automatically and, consequently, too many deleted leaf rows can lead to an unbalanced B-tree. 

BLK_GETS_PER_ACCESS: 
You can look at the BLK_GETS_PER_ACCESS column to see how much logical I/O it takes to retrieve data from the index. If this row shows a double-digit number, you should probably start rebuilding the index.

延伸 · 閱讀

精彩推薦
主站蜘蛛池模板: 久久久国产精品免费观看 | 午夜精品久久久久久久爽 | 国产手机国产手机在线 | 操操电影 | 爱操视频 | 亚洲精品 欧美 | 黄色免费视频网站 | 男女无遮挡羞羞视频 | 91精品国产乱码久久桃 | 欧美激情精品久久久久久久久久 | 一起草av在线 | 91精品国产九九九久久久亚洲 | 久夜草 | 夜添久久精品亚洲国产精品 | 2018亚洲男人天堂 | 强伦女教师视频 | 午夜在线小视频 | 久久久久国产精品久久久久 | 中文字幕在线观看视频一区 | 精品呦女 | 日本免费不卡一区二区 | www视频免费观看 | 欧美精品一区自拍a毛片在线视频 | 国产激爽大片在线播放 | 九九午夜视频 | 成人在线观看免费高清 | 毛片视频大全 | 国产扩阴视频 | 亚洲第一成av人网站懂色 | 91成人午夜性a一级毛片 | 国产小视频在线 | 99精品国产视频 | 男女隐私免费视频 | 玩偶姐姐在线观看免费 | 久久国产精品二国产精品中国洋人 | www.guochan| 欧美精品一级片 | 中文字幕激情视频 | 国产精品视频免费网站 | 精品国产一区二区三区四区阿崩 | 一级做受毛片免费大片 |