There may be times when you need to find out who has created, edited, or deleted a holiday addition on an employee’s record, along with when those changes were made.
To run an audit against a holiday additions record, follow these steps.
In the Admin Tool, click Import/Export Data.
Click Create an export definition.
Click Select the data to export.
Change the database to SELECTHR.
Log in.
Copy the below SQL:
Select Absence.HolidayAdditionsHistoryData.*, Person.Snapshot.[Person Number], Person.Snapshot.[Effective Status], Person.Snapshot.[First Name], Person.Snapshot.Surname From Person.Snapshot Inner Join Absence.HolidayAdditionsHistoryData On Person.Snapshot.[Person Number] = Absence.HolidayAdditionsHistoryData.PersonNumber Where Person.Snapshot.[First Name] = 'CHANGE ME' And Person.Snapshot.Surname = 'CHANGE ME'
In the top left of the data export window, click Options, then click Paste SQL from clipboard.
In the bottom half of the query window, change any of the CHANGEME values to reflect the First Name and Surname of the employee.
Click Data.
Make a note of the Addition Number.
Click Cancel.
Click Select the data to export.
Change the database to SELECTPERSIST.
Copy the below SQL:
Select AUDIT.[Object Schema], AUDIT.[Object Name], AUDIT.[Key Number], AUDIT.[Audit Date], AUDIT.Action, [Audit Fields].[Field Name], [Audit Fields].[Is Text], [Audit Fields].[Was Text], Security.Users.[User Name], [Audit Fields].[Is Date], [Audit Fields].[Was Date], [Audit Fields].[Is Number], [Audit Fields].[Was Number], [Audit Fields].[Was Decimal], [Audit Fields].[Is Decimal], [Audit Fields].[Was Boolean], [Audit Fields].[Is Boolean] From AUDIT Inner Join [Audit Fields] On AUDIT.[Audit Number] = [Audit Fields].[Audit Number] Inner Join Security.Users On AUDIT.[User Number] = Security.Users.[User Number] Where AUDIT.[Object Schema] = 'absence' And AUDIT.[Object Name] = 'HolidayAdditionsHistoryData' And AUDIT.[Key Number] = 'CHANGE ME'
In the top left of the data export window, click Options, Paste SQL from clipboard.
Click on the query tab, replace the CHANGEME value with the Addition Number noted in step 10 in the criteria section of the field named AUDIT.[Key Number].
It is possible to see all changes made to a holiday addition, including who created it and when.
