How to remove a user from one group if the person is already there in one group

sontam lavanya
Tera Contributor

Hi All,

 

I am new to ServiceNow, can you please help me on this issue.

 

Here I am using some conditions based on which a user is added to one group (e.g., Group A) that doesn't have any role. Later on, if we add the user to a different group (e.g., Group B), which has the ITIL role, the user should automatically be added to the group with the ITIL role (Group B) and removed from the other group (Group A). How can we achieve this automatically using Flow Designer?

 

Advance Thanks.

1 ACCEPTED SOLUTION

A business rule to do this would look like this: 

JenniferRah_0-1729172104056.png

And the script on the Advanced tab would look like this: 

JenniferRah_1-1729172140158.png

 

View solution in original post

3 REPLIES 3

JenniferRah
Mega Sage

So what you are asking is if a user is added to Group B, you want to check and see if they are a member of Group A. If so, you want to remove them from Group A?

 

This sounds like something better suited for a Business Rule than a Flow. Is there a reason you need it done as a Flow?

A business rule to do this would look like this: 

JenniferRah_0-1729172104056.png

And the script on the Advanced tab would look like this: 

JenniferRah_1-1729172140158.png

 

I want a user to be removed from Group A automatically when they are added to Group B, without manual intervention. I'm trying both Business Rules and Flow Designer, but I'm finding solutions in both approaches.