Home Forums SQL Server 2005 Data Corruption MDF-Can't Get Out Of Suspect Mode....Need Some Help Please RE: MDF-Can't Get Out Of Suspect Mode....Need Some Help Please

  • smratisharma (5/31/2010)


    To repair the database, run the following queries in Query Analyzer

    EXEC sp_resetstatus ‘yourDBname’;

    ALTER DATABASE yourDBname SET EMERGENCY

    DBCC checkdb(‘yourDBname’)

    ALTER DATABASE yourDBname SET SINGLE_USER WITH ROLLBACK IMMEDIATE

    DBCC CheckDB (‘yourDBname’, REPAIR_ALLOW_DATA_LOSS)

    ALTER DATABASE yourDBname SET MULTI_USER

    And It Repairs the Database. It Works for Me 🙂

    If you had bothered to read the initial post completely, you would have noticed that the OP tried this and the emergency mode repair failed. Hence, this advice is completely useless in this case. It is also not the recommended first approach to dealing with corruption.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass