After I restore the master database , a database is missing


Maybe the database is created after master is backed up . Because master backup set has no informaton about the new database , after master is restored , the user database will not be known to SQL Server .

In this case , if all database files comprising the user database still exist on the disk(s), the user database can be created by attaching the database files .
Just open the Query Analyzer , and then execute the following sql statements: (we attach pubs database as sample)

EXEC sp_attach_db @dbname = N'pubs',
@filename1 =N'c:\mssql7\data\pubs.mdf',
@filename2 = N'c:\mssql7\data\pubs_log.ldf'




Download ms sql server backup and restore software
Download Now
 
More 5 Start Award ....


No risk 30 days money backup guarantee


Download ms sql server backup and restore software
Download Now
 

Copyright @2005-2009 by DataBK.com, all rights reserved.