Tag Archives: dba

Shrink all SQL Server logfiles

After backing up the log files on a SQL server, the logs are truncated and you might want to reclaim the disk space held by those empty log files. This little Transact-SQL script will do just that. DBCC SQLPERF(logspace) GO DECLARE @logsize AS INT = 256; — MB DECLARE @databasename AS VARCHAR(256); DECLARE @filename VARCHAR(256); [...]

Follow

Get every new post delivered to your Inbox.