Servicenow developer
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
7 hours ago
Hi everyone,
I have created a custom table in ServiceNow, but it is not extended from the Task table.
In this table, I have a reference field to the User table (sys_user). My requirement is:
I want the User reference field to show only users who belong to a particular User Group.
The group members should be filtered so that only users in that specific group are visible/selectable.
Since my table is not extended from Task, I cannot use assignment group and assigned to functionality directly.
Could anyone please suggest the best approach to achieve this?
Specifically:
Should I use a Reference qualifier?
If yes, what would be the correct way to filter users based on group membership (sys_user_grmember)?
Is there any recommended best practice for this scenario?
Any guidance or example would be greatly appreciated.
Thanks in advance!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 hours ago
Hi @vodnalar26,
yes, the reference qualifier is the best approach.
Go to the field on the custom table, click right mouse button on that field and select Dictionary, there you have the chance to add ref qualifier for a field with reference type.
100 % GlideFather experience and 0 % generative AI
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
an hour ago
Hi @vodnalar26
I’m not sure about the use case. Since you didn’t extend the table from Task, this is a purely custom table and all the fields need to be created manually.
If you want to use User Group / User, a reference field is the best option here. As a rule of thumb, if the number of values in a dropdown is 10 or fewer, go with a choice field; otherwise, use a reference field.
Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/dratulgrover [ Connect for 1-1 Session]
****************************************************************************************************************
