Solved

Restore user database fromold mdf file

Posted on 2000-05-05
3
201 Views
Last Modified: 2008-02-26
If I have a copy of both the mbf and ldf files from a user database, but had to restore the master database, how do I restore the user database
0
Comment
Question by:madps
  • 2
3 Comments
 
LVL 2

Accepted Solution

by:
dambalaji earned 100 total points
ID: 2781694
Hi,
you planned to restore the Master databases. Then you can use the stored procedure sp_attach_db to attach your databases you created.

This example restores the master database backup from tape without using a permanent (named) backup device.

USE master

GO

RESTORE DATABASE master

    FROM TAPE = '\\.\Tape0'

GO

And then you can use

sp_attach_db [@dbname =] 'dbname',
    [@filename1 =] 'filename_n' [,...16]



For more information see "Restoring the master Database from a Current Backup  "
in BOL.

0
 

Author Comment

by:madps
ID: 2781765
Thanks if just worked ok
0
 

Author Comment

by:madps
ID: 2781766
Thanks it just worked ok
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Suggested Solutions

Introduction In my previous article (http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/SSIS/A_9150-Loading-XML-Using-SSIS.html) I showed you how the XML Source component can be used to load XML files into a SQL Server database, us…
This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
Via a live example combined with referencing Books Online, show some of the information that can be extracted from the Catalog Views in SQL Server.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now