When the database is restored, the database XXXXX cannot be processed because it is being used by this session. We recommend that you use the master database when performing this operation. Solution: 1. When you log on with an SQL account and restore it, the above error message is displayed. You can use windows to log on to restore the database. 2. If you use a query analyzer to restore the database, see restor.
When the database is restored, the database 'xxxxx' cannot be processed because it is being used by this session. We recommend that you use the master database when performing this operation. Solution: 1. When you log on with an SQL account and restore it, the above error message is displayed. You can use windows to log on to restore the database. 2. If you use a query analyzer to restore the database, see restor.
When the database is restored, the database 'xxxxx' cannot be processed because it is being used by this session. We recommend that you use the master database when performing this operation.
Solution:
1. When you log on with an SQL account and restore the database, the preceding error message is displayed. You can use windows to log on and restore the database;
2. If you use the query analyzer to restore data, see:
Restore database Auction from disk = 'path' with replace;
System. Data. SqlClient. SqlException: RESTORE cannot process database 'auction 'because it is being used by this session. We recommend that you use the master database when performing this operation. The restore database is terminating abnormally.
The error message is obvious. The statement is changed
Use master; restore database Auction from disk = 'path' with replace;
When the ms SQL server database is restored, the following error occurs:
The database 'xxxxx' cannot be processed because it is being used by this session. We recommend that you use the master database when performing this operation.
Use the following command to restore
Use master
Declare @ s varchar (8000)
Select @ s = isnull (@ s, '') + 'Kill '+ rtrim (spID) from master .. sysprocesses where dbid = db_id ('database name ')
Select @ s
Exec (@ s)
Restore database name
From disk = n' path to restore the database backup file. Bak'
With replace