On approving or rejecting approvals via email for HR cases, the HR case record is not being approved although the sysapproval_approval record is marked approved. The workflow is also stuck in the Approval Activity.

When doing an update to the HR case, the approval will be processed, and workflow continues.

The following error occurs:

WARNING * WARNING * Get for non-existent record: sn_hr_core_case_payroll:72b928b3dbd9d788ea7ba7835b9619e5, initializing.

This error occurs because the hr_Utils script include is sometimes initializing as "system" instead of the target user from the email when approvals are approved via email.


Steps to Reproduce

On a production instance:

  1. Create a case that requires approval from a user who cannot read the case otherwise.

  2. Have the user approve the case via email.

    Note that the case might not move to approved until an update is made to the record.



Add a check/reinitialize to the top of the Restrict Query business rule.

var userId = gs.getUserID();
if (userId !== hr_Utils.userID)

Related Problem: PRB1278805

Seen In

There is no data to report.

Intended Fix Version


Safe Harbor Statement

This "Intended Fix Version" information is meant to outline ServiceNow's general product direction and should not be relied upon in making a purchasing decision. The information provided here is for information purposes only and may not be incorporated into any contract. It is not a commitment, promise, or legal obligation to deliver any material, code, or functionality. The development, release, and timing of any features or functionality described for our products remains at ServiceNow's sole discretion.

Associated Community Threads

There is no data to report.

Article Information

Last Updated:2018-06-20 23:53:55