Behaviour of indexes when restoring a backup

Last post 09-18-2008 3:09 AM by cjp. 5 replies.
Page 1 of 1 (6 items)
Active Topics My Discussions Unanswered Sort Posts: Previous Next
  • 09-17-2008 6:38 AM

    • cjp
    • Top 500 Contributor
    • Joined on 08-12-2008
    • Posts 31

    Behaviour of indexes when restoring a backup

     I back up databases by using the SQLS wizard (Sequel Server 2005). Occasionally, I need to restore the backup onto a different computer. When I do this, all indexes are present but I have noticed that performance tends to be quite slow. I am wondering if the indexes are actually working under this scenario - that is, if an indexed table generated on computer x is backed up and then restored to computer y, will the indexes still work properly or should I drop and re-create them?

    Thanks.

    Chris

  • 09-17-2008 8:49 AM In reply to

    Re: Behaviour of indexes when restoring a backup

    Hi,

    You should check the execution plan and need to update the statistics or defrag the index or rebuild the index if needed.

    Hemantgiri S. Goswami | MS SQL Server MVP
    -------------------------
    "Humans don't have Caliber to PASS TIME , Time it self Pass or Fail Humans" - by Hemantgiri S. Goswami

    http://hemantgirisgoswami.blogspot.com
    http://forums.surat-user-group.org/

    View Hemantgiri S. Goswami's profile on LinkedIn

    Disclaimer: This post is provided as is, for the sake of knowledge sharing only.
  • 09-17-2008 11:46 AM In reply to

    • satya
    • Top 10 Contributor
    • Joined on 11-05-2002
    • United Kingdom
    • Posts 22,515
    • Microsoft MVP
      Moderator

    Re: Behaviour of indexes when restoring a backup

    If the both servers hardware & software is different then it is better to peform a reindex & update statistics on the database when it is restored.

    -Satya S K J

    SQL Server MVP



    Knowledge is Power, you will gain by sharing it. SSQA.net - Invisible contributions to the users & visible success in SQL Community.
  • 09-18-2008 1:52 AM In reply to

    • cjp
    • Top 500 Contributor
    • Joined on 08-12-2008
    • Posts 31

    Re: Behaviour of indexes when restoring a backup

     Thanks - both computers are running SQLS 05 but the OS's are different and the hardware specifications are different too.

    May I add a question about statistics? Where are stats held? - Are they part of the database on which they have been compiled or are they held in a system database? Would statistics be part of the backup?

    Chris

     

  • 09-18-2008 2:27 AM In reply to

    • satya
    • Top 10 Contributor
    • Joined on 11-05-2002
    • United Kingdom
    • Posts 22,515
    • Microsoft MVP
      Moderator

    Re: Behaviour of indexes when restoring a backup

    Yes the statistics are stored as system objects in the user databases, but due to the mismatch of system configuration this is useless and in order to gain them you need to perform REINDEX or UPDATE STATISTICS if there is any small change in configuration of hardware or software.

    -Satya S K J

    SQL Server MVP



    Knowledge is Power, you will gain by sharing it. SSQA.net - Invisible contributions to the users & visible success in SQL Community.
  • 09-18-2008 3:09 AM In reply to

    • cjp
    • Top 500 Contributor
    • Joined on 08-12-2008
    • Posts 31

    Re: Behaviour of indexes when restoring a backup

     Many thanks - I will incorporate these measures into my work plans from now on.

    Chris

     

Page 1 of 1 (6 items)
Active Topics   My Discussions    Unanswered Posts


© 2000 - 2007 vDerivatives Limited All Rights Reserved.