SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


AdventureWorks Attach problem


AdventureWorks Attach problem

Author
Message
river1
river1
SSChampion
SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)

Group: General Forum Members
Points: 11386 Visits: 1737
Hi,

I'm trying to attach the data file of Adventureworks. I have download the file from http://msftdbprodsamples.codeplex.com/releases/view/55330


When I try to attach the file (I remove the log file because I don't have one) I receive the following error:

The header for file 'C:\AdventureWorksDW2012_Data.mdf' is not a valid database file header. The FILE SIZE property is incorrect.


My SQL Server version is SQL Server 2012 Developer edition with sp1

Can someone help?
Andrew G
Andrew G
SSCertifiable
SSCertifiable (7.9K reputation)SSCertifiable (7.9K reputation)SSCertifiable (7.9K reputation)SSCertifiable (7.9K reputation)SSCertifiable (7.9K reputation)SSCertifiable (7.9K reputation)SSCertifiable (7.9K reputation)SSCertifiable (7.9K reputation)

Group: General Forum Members
Points: 7927 Visits: 2345
Seemed to work fine for me. Have you run the following command to attach?
CREATE DATABASE AdventureWorks2012 ON (FILENAME = 'D:\MSSQL11.MSSQLSERVER\MSSQL\DATA\AdventureWorks2012_Data.mdf') FOR ATTACH_REBUILD_LOG;


river1
river1
SSChampion
SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)

Group: General Forum Members
Points: 11386 Visits: 1737
Thank you.

It's solved
quackhandle1975
quackhandle1975
SSCertifiable
SSCertifiable (6.4K reputation)SSCertifiable (6.4K reputation)SSCertifiable (6.4K reputation)SSCertifiable (6.4K reputation)SSCertifiable (6.4K reputation)SSCertifiable (6.4K reputation)SSCertifiable (6.4K reputation)SSCertifiable (6.4K reputation)

Group: General Forum Members
Points: 6389 Visits: 1275
foxxo (3/25/2013)
Seemed to work fine for me. Have you run the following command to attach?
CREATE DATABASE AdventureWorks2012 ON (FILENAME = 'D:\MSSQL11.MSSQLSERVER\MSSQL\DATA\AdventureWorks2012_Data.mdf') FOR ATTACH_REBUILD_LOG;



Thank you!

qh

Who looks outside, dreams; who looks inside, awakes. – Carl Jung.
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum








































































































































































SQLServerCentral


Search