Sql-server – Can’t Upgrade an MDF from SQL 2005 – 2008

sql serversql-server-2005sql-server-2008

I'm trying to deploy an MDF file to my live server, but this also means going from SQL Express 2005 to 2008.

I'm getting the following error in my web page.

Database 'xxx.MDF' cannot be upgraded because it is read-only or has read-only files. Make the database or files writeable, and rerun recovery.

I've tried adding write permission to the IUSR account for the MDF and LDF file, but this doesn't work.

I've read this from MS support, but I don't really understand what I need to do in the context of an MDF file.

Has anyone else come across this and have a solution?

Thanks.

Best Answer

Try attaching the database with SQL Server Management Studio and see if the database upgrade still fails.