操作之前请备份好自己的数据:
Use Master
Go
sp_configure 'allow updates', 1
reconfigure with override
Go
begin tran
update sysdatabases set status = 32768 where name = '数据库名'
--Verify one row is updated before committing
commit tran
DBCC TRACEON(3604)
DBCC REBUILD_LOG('数据库名','c:\mssql7\data\数据库名_log.ldf')
Go
use master
update sysdatabases set status = 8 where name = '数据库名'
Go
sp_configure 'allow updates', 0
reconfigure with override
Go
dbcc checkdb(数据库名)
阅读(1001) | 评论(0) | 转发(0) |