Need to Hide Inactive Users with User ID Ending in '999' from sys_user Table (Not Visible to Anyone)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday - last edited yesterday
Hi all,
I have a requirement to completely hide certain user records from the sys_user table in ServiceNow.
Requirement:
I want to hide all user records in the sys_user table where:
The user account is inactive (active = false)
The user_id **ends with '999'`
These records should:
Not be visible to anyone, including in lists, forms, reference fields, or searches.
Be effectively hidden from all users.
What I’ve Tried:
I attempted to use a Before Query Business Rule to filter these records out, but it did not work as expected. The records still appear in list views and reference fields.
Goal:
I need a solution (script or configuration) to completely hide these users from being visible in the platform UI, ideally without deleting them from the system.
Any help or guidance on how to implement this correctly would be greatly appreciated.
Thanks in advance!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
an hour ago
Use a Before Query Business Rule + ACL Restriction
Busines rule:
ACL > Read > sys_user table
example code:
answer = !(current.active==false&¤t.user_id.endsWith('999'));