mdf is Compressed But Does not Reside in a Read-only Database or Filegroup. The File Must be Decompressed.

Last night I loaded a massive ASP.NET 2.0 project I did some years ago in VB.NET. It used a SQL 2000 database for data storage, so I had to attach the mdf file to get it to work. So I opened SQL Server Management Studio, opened a connection to the server instance, and went for the Attach database option.

When I selected the file, the following error came up:

“Store.mdf is Compressed But Does not Reside in a Read-only Database or Filegroup. The File Must be Decompressed.”

So here’s a quick tip for anyone who faces a similar issue. It took a few seconds to understand the problem but then I remembered file compression options. Opened my mdf file properties dialog box, and in the advance tab the problem was revealed: the “compress content” checkbox was checked.

After unchecking and saving changes, SQL Server accepted the attach with no problem whatsoever.

Technorati Tags:

Digg This
Reddit This
Stumble Now!
Buzz This
Vote on DZone
Share on Facebook
Bookmark this on Delicious
Kick It on DotNetKicks.com
Shout it
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Google Buzz (aka. Google Reader)

3 comments so far

  1. Keep posting stuff like this i really like it

    October 5th, 2010
  2. 002 sanket

    Thanks,I face the same problem today.. and your solution works.

    July 13th, 2011
  3. 003 Manas

    Thanks for the info. You saved my life

    March 13th, 2012

Add a comment