Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

How to assign incidents depend upon the user location?

gokulraj
Giga Expert

Hi all,

  I have a requirement to assign the assignment group automatically for all incidents depends on the user location.I need a script for this.Please, suggest   your ideas.

27 REPLIES 27

I don't know how to create a lookup.Please, help me to do that


Well,



The code that you have written, what it is doing ?


1. it checks your location and groups table for a record whose location is same as the callers location


2. If it finds such a record, the assignment group of that record will be assigned to the Incident's assignment group.



Now you need to check is that


1. what is the callers location?


2. Check the location and groups table, is there any record which has the same location, if not, you have to create a record in that table and then test the code.


HI,



Is this BR after Update or Before Update/Insert what?



Thanks