在备份一个客户的数据库时(数据库版本为SQL 2005 Express版本),做DBCC CHECKDB时遇到了下面错误信息: dbcc checkdb('DB_NAME'); 消息 5030,级别 16,状态 12,第 1 行 The database could not be exclusively locked to perform the operation. 消息 7926,级别 16,状态 1,第 1 行 Check statement aborted. The database c…
So now if you want to place AdventureWorks2008R2 sample database in a single-user mode, then write the code ALTER DATABASE AdventureWorks2008R2 SET SINGLE_USER; The above code would wait indefinitely if there is a lock on the database or users are co…