September 25, 2013 at 1:20 am
Comments posted to this topic are about the item Determine if BACKUP COMPRESSION is available
September 25, 2013 at 7:30 am
I have this version, and it does NOT support compression :
productversion:11.0.2383.0
productlevel:RTM
edition:Web Edition (64-bit)
September 26, 2013 at 7:44 am
Bert,
You are correct. I have enhanced the IF statment that sets the CompressYN flag. It is below.
Thanks for the feedback.
Mark Cook
IF (
-- Check for SQL 2012
-- Editions that support backup compression:
-- Enterprise, Business Intelligence, Standard
((SELECT CONVERT(VARCHAR(16), Verinfo) FROM @verinfoTbl) LIKE '11.%') AND
(
((SELECT CONVERT(VARCHAR(16), EditionInfo) FROM @verinfoTbl) LIKE 'Enterprise%') OR
((SELECT CONVERT(VARCHAR(16), EditionInfo) FROM @verinfoTbl) LIKE 'Business%') OR
((SELECT CONVERT(VARCHAR(16), EditionInfo) FROM @verinfoTbl) LIKE 'Standard%')
)
)
OR
(
-- Check for SQL 2008 R2
-- Editions that support backup compression:
-- DataCenter, Enterprise, Standard
((SELECT CONVERT(VARCHAR(16), Verinfo) FROM @verinfoTbl) LIKE '10.50%') AND
(
((SELECT CONVERT(VARCHAR(16), EditionInfo) FROM @verinfoTbl) LIKE 'Data%') OR
((SELECT CONVERT(VARCHAR(16), EditionInfo) FROM @verinfoTbl) LIKE 'Enterprise%') OR
((SELECT CONVERT(VARCHAR(16), EditionInfo) FROM @verinfoTbl) LIKE 'Standard%')
)
)
OR
(
-- Check for SQL 2008
-- Editions that support backup compression:
-- Enterprise
((SELECT CONVERT(VARCHAR(16), Verinfo) FROM @verinfoTbl) LIKE '10.00%') AND
(
((SELECT CONVERT(VARCHAR(16), EditionInfo) FROM @verinfoTbl) LIKE 'Enterprise%')
)
)
BEGIN
SET @CompressYN = 'Y'
END
ELSE
---- BACKUP COMPRESSION not available
BEGIN
SET @CompressYN = 'N'
END
April 27, 2016 at 4:56 pm
Thanks for the script.
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply