SQLTeam.com | Weblogs | Forums

Not a valid database


I experience the problem with MDF format document. Its not opening.

Saying: Mdf is not a valid database file header. What's the problem? What should I do?

Please give me a solution soon as possible.

What exactly are you doing, and what is the exact error message?

it might be corruption in MDF header and you may getting SQL Server error 5172. Please take a look on here to know more about it: http://www.sqlrecoverytool.com/fix-ms-sql-server-error-5172.html

You don't open MDF files, you attach them to a SQL Server database instance.
Connection to server - database folder - click Attach- add
Take a look here: https://www.openfiletool.com/mdfopen.html

The message posted by the O/P is displayed as a result of trying to attach a file :yak: