摘要:
USE master go ALTER DATABASE tempdb MODIFY FILE (NAME = tempdev, FILENAME = 'Path\tempdb.mdf') go ALTER DATABASE tempdb MODIFY FILE (NAME = templog, FILENAME = 'Path\templog.ldf') go另外清除TEMPDB中数据的最好的办法是重启SQL服务器、 阅读全文
摘要:
USE master go ALTER DATABASE tempdb MODIFY FILE (NAME = tempdev, FILENAME = 'Path\tempdb.mdf') go ALTER DATABASE tempdb MODIFY FILE (NAME = templog, FILENAME = 'Path\templog.ldf') go另外清除TEMPDB中数据的最好的办法是重启SQL服务器、 阅读全文
摘要:
一个VM的错误就造成了sql2012的脱序。很多一般看不到的模式陆续登场诸如 recovery pending, suspect, EMERGENCY.以下脚本可以帮助恢复,如果文件没有损坏的话。EXEC sp_resetstatus [DatabaseName];ALTER DATABASE [DatabaseName] SET EMERGENCYDBCC checkdb([DatabaseName])ALTER DATABASE [DatabaseName] SET SINGLE_USER WITH ROLLBACKIMMEDIATEDBCC CheckDB ([DatabaseName] 阅读全文
|