Sql-server – SQL Backup – Restoring to different data / log files – Changing file structure…

database-restorerestoresql serversql-server-2008

I'm trying to restore a BAK of a database we have, onto new, better hardware.
Here is a screenshot of the UI in Management Studio

http://twitpic.com/wmtr8/full

The existing db has an mdf, and ndf file… and two log (ldf) files…

Is there any way I can restore it so that it just has ONE mdf and ONE ldf file…?

The existing db is SQL 2000 – I'm restoring it to a SQL 2008 instance – I created the db in 2000 compatibility mode however.

…as a side note:
If i click Ok, in the screen shown above, i get the following error:

File 'D:\Navision4.LDF' is claimed by
'Navision4_Log3'(5) and
'Navision4_Log'(2). The WITH MOVE
clause can be used to relocate one or
more files. (Microsoft.SqlServer.Smo)

For help, click:
http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=10.0.1600.22+((SQL_PreRelease).080709-1414+)&LinkId=20476

Best Answer

I'd suggest restoring the database as is and then remove the superfluous log file afterward. The error is because the two logs have the same name and you're tying to restore to the same volume - restore one of them using a different name.

There may be a good reason why the database file has been split into two (one .MDF and one .NDF) check with whoever supports the application also look for filegroups.