Link to home
Start Free TrialLog in
Avatar of RichW
RichWFlag for United States of America

asked on

Not a Valid Database File Header

Hi all,

I'm trying to attach a db file to an MSDE server.

The .mdf and .ldf files attach fine to a SQL Server db either run in VB code or done through Query Analyzer.

When I try to attach the files in VB to MSDE I get the following error:

Database failed to attach
SQL-DMO error: -2147217900 The header for file 'c:\mssql7\Data\testdb.mdf' is not a valid database file header.  The PageAudit property is incorrect.

Does anyone know what the problem is?

Thanks



Avatar of Brendt Hess
Brendt Hess
Flag of United States of America image

(1)  If you are using a DPT RAID controller, check this MS article:

http://support.microsoft.com/support/kb/articles/Q268/4/81.ASP

(2)  What version of SQL Server?  MSDE?.  If SQL 2000 and MSDE 1.0 / 7.0, then you are out of luck (I think), since the MSDE expects SQL 7 format, and, although SQL 2000 can handle SQL 7 files, I don't believe the reverse is correct.

Avatar of RichW

ASKER

The tables were created in SQL Server 2000.  I'm using MSDE 1.0.  I don't know if there's an MSDE version for SQL Server 2000.  I thought 1.0 was the only version out there?

Is this the problem?
ASKER CERTIFIED SOLUTION
Avatar of Brendt Hess
Brendt Hess
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of RichW

ASKER

Thanks bhess1.  I'm gonna look for a version for SQL2k or we'll just have to downgrade.

Thanks again!