Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase 12»»

SQL Server Compatibility mode Expand / Collapse
Author
Message
Posted Friday, June 18, 2010 6:01 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Monday, July 26, 2010 11:41 PM
Points: 10, Visits: 76
Hi all,

During the day I made the migration of databases of SQL 2000 to SQL 2008.
But now I would have questions to ask.

1) The level of compatibility I have to set to 100?

2) If compatibility is set to 80 what happens?

King regards.
Post #939513
Posted Friday, June 18, 2010 8:37 AM
SSC Journeyman

SSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC JourneymanSSC Journeyman

Group: General Forum Members
Last Login: Tuesday, November 25, 2014 9:10 AM
Points: 84, Visits: 382
Hey beppe_30,

This may not fully answer your question, but as a general rule, running any database in compatibility mode is simply saying that, although you have a higher version of SQL Server installed on the server, the database will only have the features and options available to the compatibility level you've chosen for it. To my knowledge (and experience) there's never a performance penalty or gain for running in compatibility mode. You just lose features.

This is particularly helpful when consolidating databases/servers and/or you need to run a 2000 or 2005 only supported database on a SQL Server 2008 platform, for example. Now, upgrading your databases to 2008 will obviously get you the latest/greatest features, so you'd always prefer to run in native mode (the level of the SQL Server binaries installed) to get the best bang for your buck.

So to answer your original question , setting your compatibility level to 80 would just be like running your database on a SQL Server 2000 platform (albeit with better tools ).

HtH,

-Patrick


Patrick Purviance, MCDBA
Post #939649
Posted Saturday, June 19, 2010 8:25 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 9:21 AM
Points: 6,643, Visits: 14,230
An issue I noticed was, if for instance you were to go to compatibility 90 from 80 you would gain the ability for TRY..CATCH against your database but would lose the ability to execute queries using older SQL ANSI joins.

-----------------------------------------------------------------------------------------------------------

"Ya can't make an omelette without breaking just a few eggs"
Post #939963
Posted Saturday, June 19, 2010 2:01 PM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: 2 days ago @ 12:21 AM
Points: 6,743, Visits: 8,517
some DMV will not work in you are connected to a down-level db.

e.g.
use TheSQL2000db
select *from sys.dm_db_index_physical_stats(db_id(), object_id(NULL), null, null, null)

will not work on a level 80 (sql2000) db if you are connected to that db!

but
use master
select *from sys.dm_db_index_physical_stats(db_id('TheSQL2000db'), object_id(NULL), null, null, null)

will work.


Johan


Don't drive faster than your guardian angel can fly ...
but keeping both feet on the ground won't get you anywhere

- How to post Performance Problems
- How to post data/code to get the best help


- How to prevent a sore throat after hours of presenting ppt ?


"press F1 for solution", "press shift+F1 for urgent solution"


Need a bit of Powershell? How about this

Who am I ? Sometimes this is me but most of the time this is me
Post #939991
Posted Saturday, June 19, 2010 4:16 PM


SSCoach

SSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoach

Group: General Forum Members
Last Login: Today @ 9:52 AM
Points: 17,980, Visits: 15,983
As the others have said, you may not be able to use some of the DMVs. I also have just migrated a lot of 2000 databases to 2008 and have left many of them in 80 compatibility mode. The applications continue to function as they did prior to the migration and I gain some of the benefits of SQL 2008 (like compression).



Jason AKA CirqueDeSQLeil
I have given a name to my pain...
MCM SQL Server, MVP


SQL RNNR

Posting Performance Based Questions - Gail Shaw
Post #939996
Posted Monday, June 21, 2010 2:38 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Monday, July 26, 2010 11:41 PM
Points: 10, Visits: 76
Thanks to all for the answers.
Post #940157
Posted Monday, June 21, 2010 7:54 AM


SSCoach

SSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoachSSCoach

Group: General Forum Members
Last Login: Today @ 9:52 AM
Points: 17,980, Visits: 15,983
You're welcome.



Jason AKA CirqueDeSQLeil
I have given a name to my pain...
MCM SQL Server, MVP


SQL RNNR

Posting Performance Based Questions - Gail Shaw
Post #940326
Posted Tuesday, June 22, 2010 11:12 AM


Valued Member

Valued MemberValued MemberValued MemberValued MemberValued MemberValued MemberValued MemberValued Member

Group: General Forum Members
Last Login: Monday, August 11, 2014 2:43 AM
Points: 61, Visits: 700
...and the SSMS reports won't work either if the database is still in 80 mode.

David B.


David B.
Post #941236
Posted Tuesday, June 22, 2010 2:39 PM


SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Friday, June 6, 2014 5:04 AM
Points: 147, Visits: 301
I have 31Gb database that I have just set compatibility mode from 2008 to 2000 by first etting to single user mode then running:

ALTER DATABASE dbname SET COMPATIBILITY_LEVEL = 80

and it has been running for 10 minutes. Is this an action that usually takes a significant time period to complete? The server is a virtual server (a test server) and was low on memory. During execution I deleted some files to free up space. The command is still executing.

is this normal? Would it be faster if i had used the EXEC sp_dbcmptlevel dbname,80?

TIA


Love them all ... regardless.
- Buddha
Post #941349
Posted Tuesday, June 22, 2010 4:00 PM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 9:21 AM
Points: 6,643, Visits: 14,230
You most likely have an open connection or query window to the database!

-----------------------------------------------------------------------------------------------------------

"Ya can't make an omelette without breaking just a few eggs"
Post #941395
« Prev Topic | Next Topic »

Add to briefcase 12»»

Permissions Expand / Collapse