I am trying attaching AdventureWorksDW database to SSMS 2012,but unsuccessful, it it throwing error everytime. I have googled to find a solution and has tried few things, as listed:
- i have used the file named AdventureWorksDW2012_Data.mdf to attach
- Started the SSMS 2012 with Run as Administrator
- Removed the log file while attaching, so that SSMS can generate its own log file
ERROR msg:
An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)
------------------------------
The header for file 'C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\DATA\AdventureWorksDW2012_Data.mdf' is not a valid database file header. The FILE SIZE property is incorrect. (Microsoft SQL Server, Error: 5172)
Please help me to attach the file