If restoring a .bak file to a new database fails then go to these steps.
Create a new database using this script.
USE [master]
GO
CREATE DATABASE [Test] ON PRIMARY
( NAME = N'Test', FILENAME = N'C:\Test.mdf' , MAXSIZE = UNLIMITED, FILEGROWTH = 1024KB )
LOG ON
( NAME = N'Test_log', FILENAME = N'C:\Test_log.ldf' , MAXSIZE = 2048GB , FILEGROWTH = 10%)
GO
Stop sql server service.
then replace the newly created .mdf & .ldf files with your older .mdf & .ldf files.
Stop sql server service.
Refresh your server tree.
Then you are done...
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment