Coding With Fun
Home Docker Django Node.js Articles Python pip guide FAQ Policy

How to tell if sql server 2000 is compatible with sql server 2008?


Asked by Hannah Christian on Dec 12, 2021 SQL



In order to see what compatibility mode your database is in, check the sys.databases catalog view: One column is called compatibility_level and contains an INT; 80 = SQL Server 2000, 90 = SQL Server 2005, 100 = SQL Server 2008 / 2008 R2 and 110 = SQL Server 2012
Similarly,
If you are connected to a SQL Server 2000 instance you would see 70 and 80. I installed MS SQL SERVER 2008 R2 in my server and need to create a new database which compatibility level should be set to at least 90. However, the dropdowlist in the compatibility level of the database option does not include this level but 70 and 80 only.
Consequently, You can upgrade instances of SQL Server 2000, SQL Server 2005 or SQL Server 2008 to SQL Server 2008 R2. You can upgrade from SQL Server 2005, SQL Server 2008, and SQL Server 2008 R2 to SQL Server 2012. yet another option is to try to connect database (files) of sql2k to sql2k8 directly.
Moreover,
When creating a database using SQL Server Management Studio you have the ability to change the compatibility level on the "Options" tab such as follows: If we use the "Script" option we can see that SQL Server issues the CREATE DATABASE statement and then issues "sp_dbcmptlevel" to set the database compatibility level to 80 as shown below.
Thereof,
Even when you don’t change the compatibility level, you should always test your application. Because chances are high that it will give unexpected results when running it and you will have to fix them before declaring a successful migration. It all depends on the data features the application uses.