USE MASTER
GO
ALTER DATABASE {DBName} SET RECOVERY SIMPLE WITH NO_WAIT
GO
ALTER DATABASE {DBName} SET RECOVERY SIMPLE --简单模式
GO
USE {DBName}
GO
DBCC SHRINKFILE (N'{DBName}_Log' , 8, TRUNCATEONLY)
GO
USE MASTER
GO
ALTER DATABASE {DBName} SET RECOVERY FULL WITH NO_WAIT
GO
ALTER DATABASE {DBName} SET RECOVERY FULL --还原为完全模式