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.

all active computers assigned to the requested for user with a manufacturer of VMWare will autopopulate

sierra2
Mega Expert

Need the VDI name that  should be auto populate we select user.

i used cmdb table and added the dynamic query but it is only working if user is submitting the request.

please find the below screenshot for refrence

find_real_file.png

find_real_file.png

1 ACCEPTED SOLUTION

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

since it's a lookup select box did you give variable attributes as this

ref_qual_elements=requested_for

I assume requested_for is the name of the variable and give this in advanced ref qualifier

javascript: "manufacturer=817bc8a3db5c7200dfe57dfdae96190a^sys_class_name=cmdb_ci_computer^assigned_to" + current.variables.requested_for;

Regards
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

7 REPLIES 7

Aman Kumar S
Kilo Patron

Hey Buddy,

Just add "javascript: "

as in

javascript: "manufacturer......your rest of conditions....^assigned_to" + current.variables.requested_for;

 

This should work!

Best Regards
Aman Kumar

javascript: "manufacturer=817bc8a3db5c7200dfe57dfdae96190a^sys_class_name=cmdb_ci_computer^assigned_to" + current.variables.requested_for;

 

 

 this is showing the whole list.

The query is alright, what you need to do is to add

ref_qual_elements=Requested_For

Can you refer to below article:

https://community.servicenow.com/community?id=community_question&sys_id=f7918769db98dbc01dcaf3231f961998

Best Regards
Aman Kumar

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

since it's a lookup select box did you give variable attributes as this

ref_qual_elements=requested_for

I assume requested_for is the name of the variable and give this in advanced ref qualifier

javascript: "manufacturer=817bc8a3db5c7200dfe57dfdae96190a^sys_class_name=cmdb_ci_computer^assigned_to" + current.variables.requested_for;

Regards
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader