Change FULL Recovery Model to SIMPLE and Shrink Log SELECT sys.databases.name , SUM(size) * 8 / 1024 AS [Total_disk_pace_MB] FROM sys.databases JOIN sys.master_files ON sys.databases.database_id = sys.master_files.database_id GROUP BY sys.databases.name ORDER BY 2 DESC , sys.databases.name; USE master; DECLARE @isql VARCHAR(2000) , @dbname VARCHAR(64) , …