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.

Metric Definition Script to capture Assigned to and Assigned Group

kannann_
Kilo Expert

Hello All,

I have a field value Metric Definition which captures Assigned to value. I would also like to capture the Assigned Group in the value field when the Assigned to field changes. How do I do that? Please suggest.

1 ACCEPTED SOLUTION

11 REPLIES 11

yetesh_ch
ServiceNow Employee
ServiceNow Employee

Hi Kannan,



You need to use reference qualifier for your Assigned Group. I am attaching an example of use of reference qualifier:



Screen Shot 2015-10-06 at 2.35.44 PM.png


Hello Yetesh,



Thank you for your reply. I am totally new to ServiceNow, Reference Qualifier are for Reference fields right? How do I use them to get Assigned to and Assigned Group field value on a Metric which works when 'Assigned to' changes.


yetesh_ch
ServiceNow Employee
ServiceNow Employee

Oops! Its easier than that,



So, if 'Assigned Group' is set, then 'Assigned To' will only show members of that group.



Try this:


Go to Configure Dictionary of 'Assigned To' and click on "Show Advanced" link. Write <assigned_group> in Dependent field there. Note that <assigned_group> is the name of your 'Assigned Group' field.


Michael Fry1
Kilo Patron

If it's a field value Metric definition, you wouldn't be able to capture assignment group in the value section. You could switch this to a script definition and probably make that work.