1

I have a database and want to attach it in Server 2008 R2 with this script :

use master
go
CREATE DATABASE Database1
    ON (FILENAME = 'E:\proj\App_Data\Database1.mdf'),
    (FILENAME = 'E:\proj\App_Data\Database1_log.ldf')
    FOR ATTACH;
GO  

However, I am encountering these error :

Msg 1813, Level 16, State 2, Line 1
Could not open new database 'Database1'. CREATE DATABASE is aborted.

Msg 1813, Level 16, State 2, Line 1
Could not open new database 'Database1'. CREATE DATABASE is aborted.

Msg 948, Level 20, State 1, Line 1
The database 'Database1' cannot be opened because it is version 706. This server supports version 661 and earlier. A downgrade path is not supported.

sadegh
  • 1,720
  • 1
  • 16
  • 30
  • 1
    you are trying to attached sql server 2012 file to sql server 2008 SQL server is not support downgrade files – wiretext Aug 25 '15 at 12:19
  • The error message says it all: ***A downgrade path is not supported.*** You **cannot** attach a database from a newer version (2012) of SQL Server to an older engine version (2008 R2). – marc_s Aug 25 '15 at 12:25

1 Answers1

4

You cannot attach a SQL Server of higher version to a lower version(your error Msg 948 makes it very clear).

Version 706 is SQL Server 2012 and Version 661 is SQL Server 2008R2. You have to upgrade your SQL Server to the higher version.

Rahul Tripathi
  • 168,305
  • 31
  • 280
  • 331