Thank you for your feedback.
Form temporarily unavailable. Please try again or contact docfeedback@servicenow.com to submit your comments.
Versions
  • London
  • Kingston
  • Jakarta
  • Istanbul
  • Helsinki
  • Geneva
  • Store
Close

Add transactions by user related list

Add transactions by user related list

This example adds a new relationship, Last 20 transactions, to the user form.

Before you begin

Role required: admin

About this task

The new relationship creates a list of task records opened by the current user.

Procedure

  1. Navigate to System Definition > Relationships.
  2. Click New.
  3. Create a new relationship with the following values.
    OptionDescription
    Name Last 20 transactions
    Applies to table User [sys_user]
    Queries from table Task [task]
    Queries with
    current.addQuery('opened_by', parent.sys_id);
  4. Click Submit.
  5. Navigate to User Administration > Users.
  6. Select any user.
    For example, select David Loo.
  7. Configure the related lists for the user form and add the related list Last 20 transactions.
  8. Navigate to User Administration > Users.
  9. Select any user.
    For example, select David Loo.
  10. The Last 20 transactions related list displays all task records opened by the current user.

What to do next

Notes and limitations:
  • This query returns all task records opened by the user. The related list defaults to displaying 20 task records per page.
  • The parent variable refers to the Applies to table. In this case, it applies to the User [sys_user] table.
  • Querying against a record sys_id is a common query method for relationships.

This site is scheduled for a small content update on Tuesday, December 18th, between the hours of 4:00pm and 8:00pm Pacific Time (Dec 19 00:00 – Dec 19 4:00 UTC). Access to this site may be slightly delayed during that time.