Skip to page contentSkip to chat
ServiceNow support
    • Community
      Ask questions, give advice, and connect with fellow ServiceNow professionals.
      Developer
      Build, test, and deploy applications
      Documentation
      Find detailed information about ServiceNow products, apps, features, and releases.
      Impact
      Accelerate ROI and amplify your expertise.
      Learning
      Build skills with instructor-led and online training.
      Partner
      Grow your business with promotions, news, and marketing tools
      ServiceNow
      Learn about ServiceNow products & solutions.
      Store
      Download certified apps and integrations that complement ServiceNow.
      Support
      Manage your instances, access self-help, and get technical support.
In Service Portal, "sn-record-picker" directive does not support a reference field (such as department) - Known Error
  • >
  • Knowledge Base
  • >
  • Known Error (Knowledge Base)
  • >
  • In Service Portal, "sn-record-picker" directive does not support a reference field (such as department)
KB0717097

In Service Portal, "sn-record-picker" directive does not support a reference field (such as department)


10157 Views Last updated : Apr 7, 2024 public Copy Permalink
KB Summary by Now Assist

Description

This issue is with the "sn-record-picker" directive in the Service Portal. When you try and include a reference field (such as "department") in the "display-fields" parameter, the field that you specify doesn't render. When you include a non-reference field in the "display-fields" parameter (such as "user_name"), the widget renders as you would expect.

Steps to Reproduce

  1. Create a new blank widget in the Service Portal
  2. Replace the HTML Template with the contents from large_shopping_cart OOB:
    <div>
    <sn-record-picker field="" table="'sys_user'" display-field="'name'" display-fields="'user_name'" value-field="'sys_id'" search-fields="'name'" page-size="100" ></sn-record-picker>
    </div>

    large_shopping_cart Angular ng-template OOB:

    https://<instance-name>.service-now.com/sp_ng_template.do?sys_id=8a237cd06701220023c82e08f585ef98&sysparm_record_list=&sysparm_record_target=sp_ng_template&sysparm_record_row=11&sysparm_record_rows=15

  3. Save the widget and preview it.
  4. Note that the "user_name" field is displayed below the name of the user in the record picker.
  5. Replace the HTML Template with:
    <div>
    <sn-record-picker field="c.requestedFor" table="'sys_user'" display-field="'name'" display-fields="'department'" value-field="'sys_id'" search-fields="'name'" page-size="100" ></sn-record-picker>
    </div>
  6. Save the newly modified widget and preview it.
  7. Note that the "department" field does not display below the name of the user in the record picker

 

Workaround

This issue is under review. To receive notifications when more information is available, subscribe to this Known Error article by clicking the Subscribe button at the top right of the article. If you are able to upgrade, review the Fixed In or Intended Fix Version fields to determine whether any versions have a planned or permanent fix.

 


Related Problem: PRB745484

The world works with ServiceNow.

Sign in for more! There's more content available only to authenticated users Sign in for more!
Did this KB article help you?
Did this KB article help you?

How would you rate your Now Support digital experience?

*

Very unsatisfied

Unsatisfied

Neutral

Satisfied

Very satisfied

Very unsatisfied

Unsatisfied

Neutral

Satisfied

Very satisfied

What can we improve? Please select all that apply.

What are we doing well? Please select all that apply.

Tell us more

*

Do you expect a response from this feedback?

  • Terms and conditions
  • Privacy statement
  • GDPR
  • Cookie policy
  • © 2025 ServiceNow. All rights reserved.