Automating another SQL Server auditing script.


In today’s blog post I’m leveraging the work of another SQL Server MVP, Jason Brimhall. This summer Jason contributed a blog post to the July session of TSQL Tuesday. TSQL Tuesday is “a monthly blog party on the second Tuesday of each month”


In Jason’s July blog,, he presented an elegant script for detecting audit events from the default trace log. This fit in perfectly with the auditing theme that’s preoccupied much of my time this summer. So, I set out to automate it in Powershell so that I could drive the automation from any server using my typical Powershell coding approach.

This turned out to be pretty easy…

stored procedure wrapper

Continue reading “Automating another SQL Server auditing script.”

Automation of sp_Blitz with a PowerShell wrapper 

Introduction to sp_Blitz

This summer I’ve had several pressing reasons for automating Brent Ozar’s sp_Blitz, a popular SQL Server database health check script that is part of the BrentOzarULTD/SQL-Server-First-Responder-Kit.  The sp_Blitz script creates a prioritized list of issues for dba research and attention.  My main reason was for auditing, but the script checks many areas of concern.


One of my reasons for automating is to help with the ISACA database audit assurance program.  Many of the questions tie directly to areas that sp_Blitz is checking.
For example, ISACA question number, can be answered with this query:

Continue reading “Automation of sp_Blitz with a PowerShell wrapper “