日期:2014-05-16  浏览次数:20401 次

质疑库的处理

可能是因为空间不够,导致数据库'm_2007'


--允许进行系统表的操作
use master
exec sp_configure 'allow update',1 reconfigure with override
--将数据库设置成紧急模式
update sysdatabases set status=-32768 where dbid=DB_ID('m_2007')
--创建日志文件
dbcc rebuild_log ('myDoAM_2007','E:\data\m_2007_log2.ldf')
--恢复数据库的紧急模式
update sysdatabases set status=0 where name='m_2007'
--取消数据库的置疑标识
restore database m_2007 with recovery
--恢复系统表操作的设置
exec sp_configure 'allow update',0 reconfigure with override
?