September 20, 2010 at 5:13 am
I have a abc.mdf file of sql server 2000 and now i am trying to attach it to sql server 2008.
and getting this error.
exec sp_attach_single_file_db @dbname ='abc', @physname='c:\abc.mdf '
"Database 'ABC' cannot be upgraded because its non-release version (515) is not supported by this version of SQL Server. You cannot open a database that is incompatible with this version of sqlservr.exe. You must re-create the database."
Is there a way to upgrade the sql server 2000 mdf file to sql server 2008
September 20, 2010 at 5:22 am
oops i got it other way so removing the contents.
September 20, 2010 at 5:22 am
BOL instructions to copy database from earlier version
ms-help://MS.SQLCC.v10/MS.SQLSVR.v10.en/s10de_4deptrbl/html/1f7ccfc6-c68a-4038-8ad7-8d896d041f1c.htm
September 20, 2010 at 5:36 am
Try attaching and dettaching in 2005 before trying 2008 again.
September 20, 2010 at 6:07 am
nuthan_kumar (9/20/2010)
I have a abc.mdf file of sql server 2000 and now i am trying to attach it to sql server 2008.and getting this error.
exec sp_attach_single_file_db @dbname ='abc', @physname='c:\abc.mdf '
"Database 'ABC' cannot be upgraded because its non-release version (515) is not supported by this version of SQL Server. You cannot open a database that is incompatible with this version of sqlservr.exe. You must re-create the database."
Is there a way to upgrade the sql server 2000 mdf file to sql server 2008
from BOL:
You should move the log files along with the data files, even if you intend to create new log files. In some cases, reattaching a database requires its existing log files. Therefore, always keep all the detached log files until the database has been successfully attached without them.
Can you try attaching the 2000 .mdf file to an existing 2000 server and re-create the log file. Once this is done, detach the database, copy both .mdf and .ldf files and try attaching to 2008.
September 20, 2010 at 7:16 am
i tryed
"sp_attach_db 'abcd',
'D:\Old database\abcd.mdf',
'D:\Old database\abcd_log.ldf'"
GO
Then too it dint work, if i attach mdf of 2000 to 2005 it works and then from 2005 to 2008 also it works ,but directly from 2000 to 2008 it is not allowing .
The application accepts old 2000 mdf files and updates it to 2008 . the application is in vb .net
September 20, 2010 at 7:21 am
Yes i tried it it is working fine, but the client system is having only 2008 and there is an application which accepts old mdf file and update it to 2008
September 20, 2010 at 8:49 am
nuthan_kumar (9/20/2010)
I have a abc.mdf file of sql server 2000 and now i am trying to attach it to sql server 2008.and getting this error.
"Database 'ABC' cannot be upgraded because its non-release version (515) is not supported by this version of SQL Server. You cannot open a database that is incompatible with this version of sqlservr.exe. You must re-create the database."
That's not a SQL 2000 database. It's a SQL 7 database. SQL 2000 databases have version 539. It's SQL 7 databases that had a database version of 515.
There's no way to attach a SQL 7 database to SQL 2008. you need to attach it to either SQL 2000 or SQL 2005 first, let that upgrade happen, then detach again and attach to SQL 2008.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
September 21, 2010 at 3:17 am
Thanks for the information :-), Is there any stored procedure in sql which can be used to update the mdf files to the latest version,those stored procedure which i can call through .net.
September 21, 2010 at 3:22 am
Nope. The way to upgrade a SQL database (and said upgrade involves changing the internal file structure, system table definitions and a fair bit more) is to attach it to a higher version. You can attach the SQL 7 database to SQL 2000 or 2005.
Attaching to SQL 2000 will upgrade the database version to 539, attaching to SQL 2005 will upgrade the database version to 611. After which you can detach and attach to SQL 2008. SQL 2008 can only upgrade databases from SQL 2000 or 2005, nothing earlier
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
September 21, 2010 at 3:22 am
read Gail's remark:
you need to attach it to either SQL 2000 or SQL 2005 first, let that upgrade happen, then detach again and attach to SQL 2008.
Thats the only way out!!
October 20, 2010 at 3:39 pm
Attaching MS SQL 2000 DB files (mdf and ldf) in SQL 2008 is a tricky. you need to put the files in the Data folder that was created when you first installed SQL 2008. if you try to put the these files in a separate folder, you will get the read-only error message.
i tried to give the logon account of the MSSQLSERVER service administrative rights and also it did not work.
Follow the following steps to attach 2000 DB in 2008:
1. Copy both mdfs and ldfs to the folder
C:\program files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\DATA
"Do not select the reporting service folder MSRS10.MSSQLSERVER"
2. Run SQL Management Studio, right click on Database node, and select Attach...
3. In the attach database window, browse to the folder as in step 1 above.
4. Select the .mdf file, automatically the window will be filled with other details of the other ndfs and ldfs.
5. It is very important that you check the actual file path of each these files and correct to map to DATA folder that contains these files.
6. click OK and the database is attached without any error...
One important note; if you checked the properties of this attached DB, and selected options from the left side, you will find that the compatibility level is set to SQL Server 2000 (80)... change it to SQL SERVER 2008 (100), and click OK. This way you will make this DB completely migrated to 2008.
October 26, 2010 at 9:49 pm
thanks for the replay, actually i made a mistake saying that the mdf file is of Sql server 2000, the mdf file am trying to attach is of sql 7.0 and not sql server 2000. Sorry for that
October 27, 2010 at 12:47 am
SQL Server 2008 has backward compatibility with SQL server versions 2000 and 2005.
I suggest you try to attach the SQL Server 7 DB files in 2000 first and then follow the steps mentioned in earlier post.
Viewing 14 posts - 1 through 13 (of 13 total)
You must be logged in to reply to this topic. Login to reply