Sanjeev Kumar1
Kilo Sage

Hi,

If you see in cmn_location table we have country field you need to use that once user select country.

So you need to use your code like.

 

function getLocations(country_var) {
var sys_id_list = [];
var gr1 = new GlideRecord('cmn_location');
gr1.addQuery('country', country_var);
gr1.query();
while (gr1.next()) {
sys_id_list.push(gr1.sys_id);
}
var sysIDstr = sys_id_list.toString(); 
return 'sys_idIN' + sysIDstr;

}