Results 1 to 2 of 2

Thread: MDF attach error!

  1. #1

    Thread Starter
    New Member
    Join Date
    Aug 2006
    Posts
    11

    MDF attach error!

    Hi guys,
    I try to attach a mdf and i get this error .
    I suppose i need run DBCC CHECKDB but if i cant attach the database how i can run this query in it?
    Anyone can help me please!

  2. #2
    Addicted Member
    Join Date
    Oct 2008
    Location
    Califorina
    Posts
    235

    Re: MDF attach error!

    Quote Originally Posted by carlos001 View Post
    Hi guys,
    I try to attach a mdf and i get this error .
    I suppose i need run DBCC CHECKDB but if i cant attach the database how i can run this query in it?
    Anyone can help me please!

    Hopefully you have a good backup. if you don't you can try this, I don't guarantee that it will work but....What you can do is copy the bad mdf and ldf to different location. Then try restoring the MDF without the ldf, if that doesn't work create a new db (mdf and ldf) with the same name, stop the sql server, copy the old mdf and over write the new one but do not the log file. Start the sql server and hope it starts, if it does then run the dbcc checkdb. If it does work you still may have some data lost, some transactions could have not finished processing before the log file got corrupted.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width