Karthik Menon

Technical Blog

Notes on SQL Server performance troubleshooting, AWS architecture, PowerShell automation, and AI-assisted DBA work. More articles are on the way.

11 min read

The Time a Team Lead Asked 'What Changed in the Database?' and I Built a Schema Change Audit Trigger

A team lead couldn't tell a customer what changed at the sp/table/function level after a deployment. Here's the DDL trigger I built to log every schema change - old value and new value - so that question never has to be a guess again.

10 min read

The Time I Set Up a Deadlock Alert That Emails You the Actual Deadlock Graph

How I wired an Extended Events session, a SQL Agent Performance Condition alert, and a stored procedure together so that the moment a deadlock happens, the team gets an email with the real deadlock XML attached - not just 'a deadlock occurred.'

7 min read

Cell-Level Encryption in SQL Server: What I Use for HIPAA/PCI Columns, and the Key Recovery Problem That Bit Us

A practical walkthrough of cell-level encryption for protecting sensitive columns like name, email, and phone number - plus the real problem I ran into managing encryption keys across 300+ databases, and how newer SQL Server versions finally fixed it.

7 min read

Tracking Database Growth Over Time: The Daily Snapshot Method I Use

How I log daily database file sizes into a history table to spot abnormal growth trends before they turn into a disk-space emergency - plus where I'd take this further with window functions, autogrowth event tracking, and proper alerting.

6 min read

Shrinking a Data File in Chunks Without Locking Everything Up

A safer way to reclaim disk space from a large .mdf file when you're in an emergency and can't add storage - shrinking gradually in small steps instead of one large DBCC SHRINKFILE call, plus the cleanup work it creates afterward.

2 min read

Reading SQL Server Wait Statistics Without Guessing

A practical starting point for using wait statistics to figure out what SQL Server is actually waiting on, instead of guessing based on CPU or disk graphs alone.