Assignment lookup rules only get triggered if the Assignment Group is empty.

SD_Akshay
Giga Guru

I have multiple categories on my Change form.

For those categories, I have an Assignment lookup Rule set that if the category is A and sub-category is Z, the assignment group should be set to Team A. Similarly for Categories B and C.

 

Here is the problem:

If I select Category A and Sub-category Z, the Assignment  group is set to Team A. But if I change the Category to D and Sub-category to H, the assignment group is not cleared. It stays at Team A. I can manually go and change it.

 

I want to change it automatically. It gets changed when the Assignment group field is empty. But when it is not empty and I change the category and sub -category It does not changes it remains to the previous group.

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.
Regards
Akshay Kamble (SD_Akshay)
ServiceNow Developer
LinkedIn: https://www.linkedin.com/in/akshay-kamble-1504/
****************************************************************************************************************
4 REPLIES 4

Amit Verma
Kilo Patron
Kilo Patron

Hi @SD_Akshay 

 

If I understood your issue correctly, you want to clear the value of Assignment Group field i.e. Team A whenever you don't have the category and sub-category as A and Z respectively, If this is the scenario, you can create a UI policy and inside the UI policy, you can create a UI policy action to clear the variable value for Assignment Group. Please refer below example where I have considered that if the Category and Sub-category is not Inquiry/Help and Antivirus, the Assignment Group field should be cleared :

 

AmitVerma_0-1713155257099.png

 

AmitVerma_1-1713155291710.png

 

Thanks and Regards

Amit Verma


Please mark this response as correct and helpful if it assisted you with your question.

@Amit Verma Appreciated the reply

 

I'll state my issue again

 

I have Multiple Category and Sub-categories and based on that Assignment group depend so for that I've created Assignment Lookup Rule. 

I need Client script to clear Assignment group field and replace it with another group whenever I change Category and Sub-category.

For now what's the issue is If i do select category and subcategory it populates respective assignment group BUT when i select another category and subcategory the Assignment group field remains same as previous one It does not change.  

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.
Regards
Akshay Kamble (SD_Akshay)
ServiceNow Developer
LinkedIn: https://www.linkedin.com/in/akshay-kamble-1504/
****************************************************************************************************************

@SD_Akshay 

 

Please try with the UI policy as I have mentioned response to accomplish your requirement. It's a simple and no-code alternative to client script.

 

If you still want to go ahead with a client script, please let me know. I will be happy to assist.

 

Thanks and Regards

Amit Verma


Please mark this response as correct and helpful if it assisted you with your question.

KagawadePraveen
Tera Contributor

Hi @SD_Akshay 

 

Try this in UI Policy (This is extension to @Amit Verma  answer)

KagawadePraveen_0-1713167827181.png

Here Assignment group is what is set by Auto assignment.

 

Please mark this as correct answer and helpful if it resolved, or mark this helpful if this help you to reach towards solution.

Thanks
Praveen Kagawade
(Aspire Automation)