Restore failure

  • Running SQL 2K, sp3. I'm trying to restore to a database and get a message that the database is in use. I've stopped and restarted the services, issue SP_WHO2, nobody is in the database. I try to drop the database at this point as I'm getting frustrated and figure something is corrupt somewhere. Same message. This time when I issue SP_WHO2, it shows the database in use with it executing a WAITFOR. What is going on and how do I get around this??


    Terry

  • Its possible for you to block yourself from restoring a database.  If you're doing the restore from query analyzer, first check that you are not connected to the database from Enterprise Manager (just click on a different database), then be sure that your Object Browser in Query Analyzer does not have the database selected. Finally ensure that your query analyzer session is connected to a different database.  Also check any other query analyzer/enterprise manager sessions you might have open.  Now you should be able to restore (as long as no OTHER users are connected!)

    Steve

  • There were definitely no threads into the database. What I did was to fix this was shut down the services, copied the .mdf and.ldf from the production box and restarted the services. I then did a restore over it with out issue. Weird!


    Terry

Viewing 3 posts - 1 through 2 (of 2 total)

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