Missing Indexes

  • Have given a list of missing indexes. How to decide which indexes are to be created. Please help urgenly:-)

  • Test them.

    Measure the performance with and without the indexes that you believe are required for the tasks that are required. Not all recommendations are correct.

  • one scenario may benefit from creating ,other scenarios may not. So how to decide ? how many scenarios to test? 🙂

  • mandir.jain (2/18/2014)


    one scenario may benefit from creating ,other scenarios may not. So how to decide ? how many scenarios to test? 🙂

    Indeed. And somebody has to make the decision which change to make, depending upon the impact it has under different scenarios. They have to understand, by testing, what the benefits are and ensure that they outweigh the negative impact.

    Part of a DBA role, oddly enough.

  • BrainDonor (2/18/2014)


    mandir.jain (2/18/2014)


    one scenario may benefit from creating ,other scenarios may not. So how to decide ? how many scenarios to test? 🙂

    Indeed. And somebody has to make the decision which change to make, depending upon the impact it has under different scenarios. They have to understand, by testing, what the benefits are and ensure that they outweigh the negative impact.

    Part of a DBA role, oddly enough.

    If the table is large and the indexes are wide, it can have a MAJOR impact on things that people forget about. First, the creation of ALL Non-Clustered indexes isn't much more than a duplication of data sorted in a particular order. If people "go nuts" with wide "covering indexes" that work for just one report, then you can very easily double, triple, or even quadruple (sometimes, even worse) the size of the database. That means....

    1. More disk space required that you may not have.

    2. Index maintenance will become significantly longer,

    3. Backups will take significantly longer.

    4. Backups to disk will take significantly more disk space that you may not have.

    5. Storage on table will become significantly larger.

    6. Restores will take significantly longer.

    7. INSERTs and DELETEs will take significantly longer. UPDATEs could take significantly long depending on what is being updated and what the index columns are based on. Duration and resource usage during large batch processes may require some serious attention depending on how many indexes are impacted by the batch runs.

    8. REORGANIZEing big indexes will always have an impact on the size of the log file. REBUILDing indexes will have a large impact on the log file if the database is in the FULL recovery model.

    9. Mirroring could take significantly longer and use significantly more resources.

    The addition of indexes (even some of the more narrow indexes) should not be a willy-nilly exercise based only on the performance of SELECTs. Frequently, writing better code is more effective than trying to throw an index at a problem. As "BrainDonor" previously stated, the only way to know for sure is to test but now you know of a couple of other things that you should test for other than whether or not a query or two meet duration SLAs.

    You should also do a search for "Kimberly Trip Index MCM Training". It can be a huge help.

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

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

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