MikeBennyhoffJan 5, 20231 min readQuery how many days has the server been running without a reboot?Method #1 Select dateDiff(day,login_time, GetDate()) as 'Days Running' From sys.dm_exec_sessions WHERE login_time = (SELECT...
MikeBennyhoffJan 3, 202311 min readSQL Server Locking, Blocking, And Deadlocks Information on SQL Server Locking and Blocking - How to detect, manage and kill blockers - Sample T-SQL code for blocking alerts
MikeBennyhoffJan 3, 20238 min readSQL Server Kill Process Ways to kill a process in SQL Server, including SSMS and the Kill command, why killing a process has drawbacks
MikeBennyhoffJan 3, 20234 min readSQL Server, StatisticsIn SQL Server, statistics are used by the query optimizer to determine the most efficient way to execute a query. Statistics are created...
MikeBennyhoffNov 7, 20222 min readAre Headhunter’s Evil? On my first foray into consulting, I was recruited by an agency...a head hunter. They had contracted with a customer and wanted to hire...