Index pages

  • Hi! i need to know if there is any table or buffer which stores the index pages of each index

    TIA

  • I don't know exactly what do you nead by storing the index pages.

    The index and data pages are stored within the operating system files you defined in your create db command.

    within the sysindex table you only have stored the id of the filegroup where the data itself is stored. You cannot even know (at least I don't know how) in which file your data is stored if you have several files within a filegroup.



    Bye
    Gabor

  • MSPRESS's Inside SQL Server gives a very detailed look at the structure of the data files, and Book's Online goes into some detail on it as well. You can trace the IAM chain to locate individual pages, though I can't think of any reason for doing it.

  • Maybe mi explanation wasn't very clear...i only have the address of a index page that was corrupted, and i need to know which is this index to rebuild it . Any ideas?

  • An address in memory, or an address in the file? If it's the address from the file, you track it through the IAM chain, and then track the chain back to the origionating link, though to be honest, I don't remember seeing the index name when I was playing with it, but that was not my purpose for exploring it either.

    If it's an address from memory (such as from a memory dump), good luck, as the memory locations of objects in a dynamic enviroment are anyone's guess at any given time.

    Out of curiosity, what gave you the address of an index, rather than the name? I've never seen that.

  • In sysindexes you have the first page of the datafile. The one that SQL uses to start scanning an index.

    You can't know the pages an index has. With the undocumented DBCC PAGES you can know if a page belongs to the index and also check the next page and the previous.

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply