Netwrix Auditor for SQL Server reports creation and deletion of the stored procedures by default. However, there is no way to report the modification of the store procedure, e.g. modification of the stored procedure’s query.
You can adjust Netwrix configuration to enable auditing of the “Date modified” attribute for stored procedures. This allows you to track the time of the modifications.
NOTE, in that case, Netwrix will only report on the “Date modified” attribute. No addition details about the modification performed will not be included in the report.
Follow the steps below to enable auditing of the “Date Modified” attribute for stored procedure objects:
- Open Omitproplist.txt file located in %Netwrix Installation folder%\SQL Server Auditing (default path C:\Program Files (x86)\Netwrix Auditor\SQL Server Auditing)
- Comment *.Date Modified.* line by putting the # sign in front of the * sign. The line should like like this: #*.Date Modified.*
- Exclude “Date Modified”attribute for other SQL Server objects by adding the following lines to the same file:
Application Role.Date Modified.*
Database Role.Date Modified.*
Jobs Schedules.Date Modified.*
Server Instance.Date Modified.*
Server Role.Date Modified.*
#Stored Procedure.Date Modified.*
You can copy the lines above to the file.
Starting from the next scheduled collection Netwrix Auditor for SQL server will collect data about changes made to the “Date Modified” attribute for stored procedure objects.