我的下属使用delete语句错误地删除了数据库表中的所有记录而没有where子句没有先前的备份。现在我想从mdf文件恢复 但我一直收到这个错误:
An exception occurred while executing a Transact-SQL statement or batch.
(Microsoft.SqlServer.ConnectionInfo)
ADDITIONAL INFORMATION:
Cannot open backup device 'C:\Program Files\Microsoft SQL
Server\MSSQL10.MSSQLSERVER \MSSQL\DATA\Mydabasename.mdf'.
Operating system error 32(The process cannot access the file
because it is being used by another process.).
RESTORE HEADERONLY is terminating abnormally.
(Microsoft SQL Server, Error: 3201)