Dependent variable in record producer.

pinky yadav
Mega Guru

Hi,

I want to make Subcategory dependent on category variable in record producer.I use following javascript code in reference qualifier and use Choice table . Its not working. Kindly let me know another approach for it.

javascript:'name=sn_si_incident^element=subcategory^dependent_value='+current.variable.category

6 REPLIES 6

Pradeep Sharma
ServiceNow Employee
ServiceNow Employee

Hi Pinky,

Please refer to Ratul's response to similar question here https://community.servicenow.com/community?id=community_question&sys_id=a1a1ce96dbacb304a39a0b55ca96...

 

-Pradeep Sharma

Hi Pradeep,

Thank you for your help!

I tried each method mention in that link , but it is not working as I'm not allowed to change system property and GlideRecord is not working in  client script of new releases of service Now. Kindly let me know another approach for it.

Hemant Goldar
Mega Sage
Mega Sage

Hi,

try below javascript

javascript:'name=sn_si_incident^element=subcategory^dependent_value='+current.variables.category




Hope this helps!

Please mark the reply as Helpful/Correct, if applicable.

Regards,
Hemant

Harish Kumar3
Mega Guru

Hi Pinky,

To make variable dependent on record producer form use below steps:

1. Select variable type as lookup select box.

2. configure other details like  question, name, map to field etc.

3. Under tab "Type specification" configure below fields:

       Lookup from Table  -  sys_choice
       Lookup value field  -       Value
       Lookup label field   -    label

Ref qual. - 

javascript:'name=sn_si_incident^element=subcategory^dependent_value='+current.variables.category

4. Under tab "Defualt value"configure below fields:

      variable attribute- ref_qual_elements=category

-
Harish