log_reuse_wait_desc tells you why SQL Server cannot reuse its transaction log, so you know why a shrink gives nothing back. This post causes LOG_BACKUP and ACTIVE_TRANSACTION on purpose in a test database on SQL Server 2025, measures the log and fixes each one.
Ordering a Maintenance Window: Backups, CHECKDB and Index Work
Order a maintenance window by listing Agent schedules, separating CHECKDB, backups, index work, and statistics, then tracking growth.
Statistics Histograms Explained
Statistics histograms explained through steps, RANGE_ROWS, EQ_ROWS, and DBCC SHOW_STATISTICS help connect data shape to plan estimates.
SQL SERVER – Shrinking Database is Bad – Increases Fragmentation – Reduces Performance
Shrinking database is bad: it increases fragmentation and reduces performance. Here is a simple example with two tables that shows it step by step.
SQL SERVER – Shrinking Database NDF and MDF Files
Previously, I had written a blog post about SQL SERVER. I am posting this blog post here about Shrinking Database.
SQL SERVER – Get Last Running Query Based on SPID
How to see the last running query of another session based on its SPID, using @@SPID to find session IDs and DBCC INPUTBUFFER to read the query.
Trace Flags Worth Knowing About
Review trace flags worth knowing about in current SQL Server, distinguish session, global, and startup scope, and verify each flag’s support.







