Key value pair in system property

gowdash
Mega Guru

Dear Experts,

I have a requirement to create a select box type variable to hold 200 entries. The entries might get changed frequently so I thought of using a custom table to store the records and do a reference variable. However, I would like to know is there a possibility to store these entries in the form of JSON in a system property, use client script and script include to parse the JSON from the system property and add options to the field.

Please let me know how to do it. Thanks!

Regards,

Gowdash

2 REPLIES 2

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

yes it is good practice in such cases to create system property. you can get the property value and return the value to client script;

client script can then parse the string as json object and get the values and then set the options

Mark Correct if this solves your issue and also mark 👍 Helpful if you find my response worthy based on the impact.
Thanks
Ankur

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

Ankur Bawiskar
Tera Patron
Tera Patron

Glad that it helped.

Saying this, I will appreciate if you close this thread & mark answer as correct, 👍 helpful

Regards

Ankur

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