Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Restoring from script
Message
 
À
10/06/2010 15:06:55
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Copies de sauvegarde
Versions des environnements
SQL Server:
SQL Server 2008
Application:
Web
Divers
Thread ID:
01468358
Message ID:
01468359
Vues:
58
This message has been marked as the solution to the initial question of the thread.
>Instead of always using the interface, I thought I would script the restore procedure. So, I tried this:
>
>
>RESTORE DATABASE [LevelExtreme] FROM  DISK = N'D:\Data\Level Extreme\LevelExtreme.bak'
> WITH  FILE = 1,  NOUNLOAD,  REPLACE,  STATS = 10
>GO
>
>
>But, I obtain this:
>
>Msg 3102, Level 16, State 1, Line 1
>RESTORE cannot process database 'LevelExtreme' because it is in use by this session. It is recommended that the master database be used when performing this operation.
>Msg 3013, Level 16, State 1, Line 1
>RESTORE DATABASE is terminating abnormally.
>
>What else is missing in this script so I can execute it?

USE Master
____________________________________

Don't Tread on Me

Overthrow the federal government NOW!
____________________________________
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform