SqlServer2008日志压缩语句如下: 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' , 11, TRUNCATEONLY) GO USE [master] GO ALTER DATABASE DBName SET RECOVERY FULL WITH NO_WAIT GO ALTER DATABASE DBName SET RECOVERY FULL --还原为完全模式 GO --如下语句可查看数据库文件相差属性 Use DBName SELECT * FROM sys.database_files