Approval records disappear, if you remove approvers with a slushbucket??!!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-12-2013 02:13 PM
There is a list of approvers on a change request form, which can be manually edited with a slushbucket. When you remove an approver from the list, the approval record (sysapproval_approver table) just disappears, even if it was approved/rejected before!!
...Is there any way how to find those records (removed approvals) in the system?
- Labels:
-
Change Management

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-13-2013 07:48 AM
It seems that 'Approval for:' field is not audited and there is no way how you can find history of changes for that field!
Is that true?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-13-2013 08:19 AM
I think the more likely explanation is that the insert of a record isn't audited. Updates are. So if "Approval for" happens to change, then the change gets audited, but the initial insert doesn't generate an audit record.
This behavior is customizable, but it's not recommended. We found that maybe 80% of the size of the typical sys_audit table was for inserts, which made the table get pretty big pretty fast (performance issue). In normal circumstances (i.e., anything other than trying to find the initial values of an un-updated deleted record), this is fine, since initial value can be determined either by 1) looking at the "before" value of the first audited update, or 2) looking at the current value of an un-updated record.
The property is glide.sys.audit_inserts, if you wish to change it. It won't help you this time, but might help next time if this happens again. At the cost of a dramatically increased sys_audit table size.
http://wiki.servicenow.com/index.php?title=Viewing_History_Sets

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-13-2013 08:34 AM
So if "Approval for" happens to change, then the change gets audited
That doesn't work - I changed 'Approval for' several times, but there is no information about those changes in a history set.
Steps to reproduce:
1. Create anapproval record for any ticket.
2. change 'Approval for' field and save the approval record.
3. change 'Approval for' field once again and save the approval record.
4. try to find history of 'Approval for' field changes in a history set ('Audit History' list or 'Audit Records' list).
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-13-2013 09:03 AM
Wow, you're right. Strange. I can't tell why changes to that field don't get audited. There's no business rule I can see doing anything weird, it doesn't have the no_audit attribute...
I'm at a loss.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-13-2013 12:33 PM
For auditing purposes we can use "Approval history" field on a parent ticket, but I found another strange thing:
- "Approval history" field doesn't know when you add or remove approvals - this is true for change requests only. But for custom tables, which extend 'task' table, you can see when the corresponding approver has been added or removed.
The problem is that I cannot find a business rule/script, which is responsible to populate "Approval history" filed with information about newly added or removed approvers!
I found a business rule (Approval Events (Task)), which is being used to populate approval status changes, but it's not about who&when has been added as an approver. See the screenshot attached.
Do you have any ideas on what rule/script is being used to add "[name] added as an approver" to "Approval history" field?
I'm afraid this may cause an issue for auditors..