- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-20-2025 04:51 AM
Hi Everyone,
Can anyone please help me out how to deactivate the groups which has NO Users using Flow Designer. I have tried but not able to get the desired results. Please find the attached screenshot for reference.
Thanks in advance
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-20-2025 08:04 PM
Hope you are doing good.
Did my reply answer your question?
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-20-2025 04:58 AM
you can do this
1) Lookup Records on sys_user_group
2) Then use For Each on Step 1
3) Then Lookup Records on sys_user_grmember with the Group from Step 2
4) Use IF and check outcome is Success or Failure
5) If failure means no user present
6) then use Update Record and deactivate the group
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-20-2025 05:06 AM
something like this
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-20-2025 05:50 AM
Hi @Ankur Bawiskar ,
Thank you for the information. I have updated the flow as you have shown, but i am not getting desired output. when i ran the attached script getting 17 records which has no users, but when tested with flow count 2 is showing which has users. flow logic should show the groups which has no users If i am not wrong!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-20-2025 06:20 AM
it should work fine.
Share what flow did you configure?
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader