HR criteria defines the audience for HR content, services, or cases. You can make information available to or create an HR case for specific groups, individuals, or to all employees using HR criteria.

HR criteria uses the standard platform condition builder to support complex conditions for controlling the Employee Center content that employees see when logged in. For more information, see Condition builder.

HR criteria contains a script include that can be called from an advanced User criteria.
Note: Complex conditional statements for scripted User criteria applied to a knowledge base with large amounts of documents can cause performance issues. Standard (non-scripted) User criteria is recommended for securing knowledge documents.

See User criteria for Service Portal.

HR criteria define conditions that are evaluated against HR tables. Once HR criteria is defined, you can filter what is available to those users.

HR criteria helps group people using a condition builder on any table. User criteria is used across the ServiceNow platform to filter catalog items, Service Portal widgets, and knowledge articles. User criteria filters users based on role, department, group, location, or company. User criteria can be created when HR criteria is created. HR criteria:

  • Filters content on the Employee Center.
  • Applies only to Subject person. HR criteria filters HR services based on the Subject person during case creation or transfer.
  • Filters Lifecycle Event Activities in the Human Resources Scoped App: Lifecycle Events [com.sn_hr_lifecycle_events] plugin.
  • Selects document template for HR cases.
  • Selects users when creating bulk HR cases.
For Lifecycle Events, activities have associated HR criteria that determines when to trigger an activity for the subject person selected on the Lifecycle event case. This step helps to personalize the workflow for the subject person.
Note: For HR Catalog Items (record producers), ensure Use "User Criteria" to define access to catalog items and categories is set to Yes under Service Catalog > Catalog Administration > Properties. Verify that this field is checked Yes.

You can use user criteria for Knowledge and Service catalog access. Add a reference column to the User Criteria [user_criteria] table when columns are required for the criteria query.

If you use HR criteria for Knowledge and Service catalog access, ensure:

  • Referenced columns are correctly indexed.
  • Conditions that can cause performance issues (starts with) are not used.
  • Knowledge document searches and use cases are performance tested with instances that are similar to what is used in production.

When defining conditions like case sensitivity or null values, see API GlideFilter - Scoped, Global.

Configure an HR criteria record

Create or modify HR criteria to define an audience for HR content, services, or cases.

Before you begin

Role required: sn_hr_core.admin

HR criteria uses the standard condition builder. For more information, see Condition builder .

Procedure

  1. Navigate to All > HR Administration > HR Criteria.
  2. Click New or open a record.
  3. Fill in the fields on the form.
    Table 1. HR Criteria form
    Field Description
    Name Name of the HR criteria record.
    Description Description of the HR criteria.
    Active Option to activate the HR criteria for use.
    Related user criteria You can create user criteria from HR criteria. User criteria is used across the ServiceNow platform to filter catalog items, HR Service Portal widgets, and knowledge articles.
    Note: This field remains blank until you create User criteria.

    The Create User Criteria link appears after you click Save.

  4. Click Save.
    You can create User criteria based on HR criteria. User criteria is used across the ServiceNow platform to filter catalog items, HR Service Portal widgets, and knowledge articles.
  5. Select the Create User Criteria related link.
    1. Click New or Edit to open an existing record.
    2. Fill in the fields on the form.
      Table 2. HR Condition form
      Field Description
      Name Name of the HR condition.
      Table Table that the HR condition is associated with.

      The table HR criteria conditions are defined from.

      For example, select the HR Profile (sn_hr_core_profile) table to select a field and define a condition.

      Active Option to activate the HR condition for use.
      User column Together with the Table field, filters users when evaluating a condition for a user.

      To create User criteria, select User.

      Note: Depending on the table selected, this field can be required to match conditions. When the User [sys_user] table is selected, this field is mandatory otherwise a false positive can occur since the lookup is not associated to an expected user.
      Condition The field from the table selected and a value that defines the condition.

      Use conditions to define your HR criteria.

      For example, to define a single condition, you can select the following from the HR Profile (sn_hr_core_profile) table:
      • Home country
      • is
      • United States of America
      This condition selects all employees who have a home country of the United States on their HR profile record.

      You can define multiple conditions for an HR criteria using the And Or condition filters. When using And each condition must be met. When using Or any condition that is met is used.

      For more information, see Condition builder .

      Note: When you use multiple conditions, only the records that match all of the conditions are used.
      When defining conditions like case sensitivity or null values, see API GlideFilter - Scoped, Global.
      Note: For more information, see Filters.
      For example, to create a condition to show the link for new hires and contractors, select:
      • Table: Client Role Rule [sn_hr_core_client_role_rule]
      • Condition: [Role] [is] [sn_hr_core.hrsm_new_hire] AND [Role] [is] [sn_hr_core.hrsm_contractor]
      After creating a condition, a clickable link appears with the number of matching records. Click the link to see if the correct users are being selected based on the condition.
    3. Click Submit or Update.
  6. In the Conditions section, you can add more conditions to define the HR criteria.