DBCC IND has three parameters. The first parameter is the database name or the database ID. The second parameter is the object name or object ID within the database. The third parameter is a specific index ID or one of the values 0, -1, or −2.
Here's the syntax:
DBCC IND ({'dbname' | dbid }, {
'objname' | objid }, { indid | 0 | -1 | -2 })
| 0 | Displays the page numbers for all IAMs and data pages. |
| -1 | Displays the page numbers for all IAMs, data pages, and index pages. |
| -2 | Displays the page numbers for all IAMs. |
| indid | Displays the page numbers for all IAMs and index pages for this index. If the index ID is 1 (meaning the clustered index), the data pages are also displayed. |
The columns mean:
-
PageFID - the file ID of the page
-
PagePID - the page number in the file
-
IAMFID - the file ID of the IAM page that maps this page (this will be NULL for IAM pages themselves as they're not self-referential)
-
IAMPID - the page number in the file of the IAM page that maps this page
-
ObjectID - the ID of the object this page is part of
-
IndexID - the ID of the index this page is part of
-
PartitionNumber - the partition number (as defined by the partitioning scheme for the index) of the partition this page is part of
-
PartitionID - the internal ID of the partition this page is part of
-
iam_chain_type - see IAM chains and allocation units in SQL Server 2005
-
PageType - the page type. Some common ones are:
-
1 - data page
-
2 - index page
-
3 and 4 - text pages
-
8 - GAM page
-
9 - SGAM page
-
10 - IAM page
-
11 - PFS page
-
-
IndexLevel - what level the page is at in the index (if at all). Remember that index levels go from 0 at the leaf to N at the root page (except in clustered indexes in SQL Server 2000 and 7.0 - where there's a 0 at the leaf level (data pages) and a 0 at the next level up (first level of index pages))
-
NextPageFID and NextPagePID - the page ID of the next page in the doubly-linked list of pages at this level of the index
-
PrevPageFID and PrevPagePID - the page ID of the previous page in the doubly-linked list of pages at this level of the index
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/37724/viewspace-1021252/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/37724/viewspace-1021252/
本文介绍了DBCCIND命令的使用方法及其三个参数的意义。该命令可用于显示数据库中IAM、数据页和索引页的页号。文章还解释了各列的具体含义,包括文件ID、页号、IAM映射页号等,并提供了不同参数值的效果说明。
2169

被折叠的 条评论
为什么被折叠?



