Home | Contact | Links
spcHome
spcSQL Server Backup
spcDownload
spcPurchase
spcSupport
   spcFAQs
   spcSubmit Ticket
spcAffiliate
spcContact
spcLinks
After I restore the master database , a database is missing.   Back


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'
Copyright @2007 by Databk.com. All Rights Reserved. Home | Contact | Links