无法打开数据库。恢复操作已将数据库标记为suspect
nbsp; below script,you will shrink you database log files
immediately, in my experience,you need to run the script for 3 or
4 minutes before stopping it manually */
use databasename
dbcc shrinkfile(2,notruncate)
dbcc shrinkfile(2,truncateonly)
create table t1(char1 char(4000))
go
declare @i int
select @i=0
while(1=1)
begin
while(@i<100)
begin
INSERT INTO T1 VALUES ('A')
SELECT @I=@I+1
END
TRUNCATE table T1
BACKUP LOG youdatabasename with truncate_only
end
GO
注意 只有在您的主要支持提供者指导下或有疑难解答建议的做法时,才可以使用
sp_resetstatus。否则,可能会损坏数据库。
由于该过程修改了系统表,系统管理员必须在运行 sp_resetstatus这个过程前,启用系统表更新。要
启 用更新,使用下面的过程:
USE master
GO
sp_configure 'allow updates', 1
GO
RECONFIGURE WITH OVERRIDE
GO
过程创建后,立即禁用系统表更新:
sp_configure 'allow updates', 0
GO
RECONFIGURE WITH OVERRIDE
GO
只有系统管理员才能执行 sp_resetstatus。执行该过程后,立即关闭 SQL Server。