Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

BACKUP DATABASE WITH COMPRESSION is not supported on Web Edition (64-bit)

Tags:

sql-server

I'm getting the error

BACKUP DATABASE WITH COMPRESSION is not supported on Web Edition (64-bit) 

while doing this query that NOT contains the WITH COMPRESSION clause:

BACKUP DATABASE bfsdfsdf
       TO  DISK = N'C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\Backup\blablabla.bak' 
       WITH NOFORMAT, NOINIT,
       NAME = N'blablabla-Full Database Backup', 
       SKIP, NOREWIND, NOUNLOAD,  STATS = 10
GO

I'm doing the query in SSMS installed on the server. I'm using SQL Server 2008 Web edition, and I know that this edition don't support backup compression, but in my query I'm not requesting compression!

like image 681
Marco Marsala Avatar asked Jul 01 '14 21:07

Marco Marsala


People also ask

How do I enable backup compression in SQL Server?

Using SQL Server Management Studio In Object Explorer, right-click a server and select Properties. Click the Database settings node. Under Backup and restore, Compress backup shows the current setting of the backup compression default option.

Does SQL Server 2012 Standard Edition support backup compression?

Nope. SQL Server 2012 doesn't support compressed backups in Web Edition (for example).

When can we use backup compression?

Typically, if a page contains several rows in which a field contains the same value, significant compression might occur for that value. In contrast, for a database that contains random data or that contains only one large row per page, a compressed backup would be almost as large as an uncompressed backup.


2 Answers

Solved changing the file name.

The default was NO_COMPRESSION but the .bak file already existed and was a compressed one (created on another local machine with SQL standard, and then copied on this server). In this case the default is always with compression. I discovered because putting no_compression leads me to another error saying the media is compressed.

Changing file name or deleting .bak file solved the issue.

like image 166
Marco Marsala Avatar answered Sep 17 '22 06:09

Marco Marsala


The server has a default compression setting that is used if you don't specify an option in your BACKUP statement. (Why it might allow you to set compression-by-default if your edition doesn't support it I have no idea; unfortunately I don't have a Web edition to test that theory).

Try adding WITH NO_COMPRESSION to your statement.

like image 24
dpw Avatar answered Sep 17 '22 06:09

dpw