42 views

Cause:

This is an expected behavior. It happens when the filter condition is(dynamic) - One of my groups returns all the groups of the user and also the parent groups associated with these groups.

The dynamic filter is returning all the groups that a user is part of and also the parents of these groups. 

Solution:

  • One way to achieve the solution could be to write a custom function that returns only the groups(child) that a user is part of.
  • This function can then be used in the 'Script' field of One of my groups dynamic filter definition.
  • While writing the custom script you can make use of the 'sys_user_grmember' table which has relationship between a user and all the active groups he is part of.
  • Please use the below articles for reference:
  • Changing or Creating a new getMyGroups() function
  • Advanced 'getMyGroups' function  ( NOTE: The scripts are examples to achieve the custom requirements. The examples shown in community links are not owned or tested by ServiceNow)

Article Information

Last Updated:2018-03-17 10:15:55
Published:2018-03-17