Thursday, 7 July 2016

Field level Audit

Field level audit track changes to one or more fields on a PeopleSoft record and stores the results in the delivered PSAUDIT table. You can enable as many as fields for auditing in a record. Field level audit only applicable to data updated through online and not directly through the database. So auditing will not apply to data updated by SQRs and SQL scripts.

How to enable Field Level Audit

To enable field level auditing, open the record containing the chosen field and go to the Record field properties of the field(s). In the Audit group box, Field Add, Field Delete, Field Change are the available options. Check the boxes to choose appropriate level of audit.


Type of Field Level Audit


Field Add option will track whenever a value is added to that selected field. 
Field Change option will create an entry whenever you change the value of the field.
Field Delete option, a new row is created in the audit record whenever the field value is deleted.

The record PSAUDIT stores the new and old value of the field along with the audit action. It also stores the record name and key fields of of row in the PeopleSoft record that was modified so that you can track back to it. These are the values that appear in the fields KEY1, KEY2, KEY3….
AUDIT_ACTN field stores what was the change made to the field. The values of this field can be interpreted as follows.

A – Added new value or row
C – Changed the existing value or row
D – Deleted the old value or row
K – Row updated, Old Value
N –Row Updated, New Value
O – Original Value

Query to check Field Level Audit


select * from psaudit where recname = '< Record Name>' and fieldname = '< Field Name>' and key1 = '<First Key Value>'

You can add KEY1, KEY2 on the basis of keys in your base record i.e.. the record on which field level audit is applied.


No comments:

Post a Comment