How to find who changed Passport Document Type

This method can be used to audit who made changes to the EmployeeDocument type from Configure.


Step-by-step guide

  1. First find out the employeeid of the person in question using the below script

    select ID from dbo.employee where empcode='XYZ'
  2. Find out the EmpoyeeDocumentID from the EmployeeDocument table for the document in question

    select * from dbo.employeedocument where employeeid=ABC
  3. Use the below script to  find out the audit results

    select * from dbo.employeeaudit where tablename='dbo.[EmployeeDocument]' and columnname='[DocumentTypeId]' and primarykey IN
    (select ID from employeedocument where employeeid=ABC and documenttypeid=PQR)

It will come up like below