Auditing SQL Agent job creation and deletion

SQL Agent jobs are added / removed using stored procedure interface sp_add_job and sp_delete_job. Customers have asked us how we could track user who has created a job / deleted a specific job. You could accomplish this using SQL Server Auditing feature. You can turn on Auditing to track and log stored procedure execution requests to file log / windows event log.

Following sample T-SQL code can be used to track and log execution requests to sp_add_job and sp_delete_job stored procedures

Rest of this blog entry is available at our team blog: 

This posting is provided "AS IS" with no warranties, and confers no rights. 
Use of included script samples are subject to the terms specified at

Comments (0)

Skip to main content