- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2025 06:32 AM
Hi ,
we have set many system properties which contains table names comma separated.
Example: hard.ci.pop
1)need to call this property from Script Include
2) the result of this should be : 'Configuration Item' field should display records only from these tables.
How do I achieve this
Thanks
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-01-2025 04:23 AM
Hi @Nisha30 ,
in the question you have share the property screenshot value contains ";" at the end
remove the ";" at the end of the property value in the system property
update the ref qual as below
javascript: "sys_class_nameIN" + new global.getincTables().getTableNames(current.getValue('category'));
update/keep the script include method as below
getTableNames: function(chkcategory) {
chkcategory = chkcategory.toLowerCase();
if (chkcategory == 'hardware')
return gs.getProperty('inc.filter.hardware');
else if (chkcategory == 'software')
return gs.getProperty('inc.filter.software')
else if (chkcategory == 'exchange')
return gs.getProperty('inc.filter.exchange')
else
return ''
}
Please mark my answer as helpful/correct if it resolves your query.
Regards,
Chaitanya
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-01-2025 03:56 AM
yes i can see in logs for below you suggested and all logs .
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-01-2025 04:32 AM
so category is getting printed fine?
did you check the dictionary override point which I mentioned?
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-01-2025 04:39 AM
the CATEGORY is giving logs yes.
1. when i open the CI field from incident, it opens the task dictionary and thats where i have put reference qualifier now.
2. Dictionary override in task table for me as below , i dont have for incident, is that something to be created ? and update with Reference qualifier there? and should the task ref qualifier be removed then?
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-01-2025 05:05 AM
yes you should create a dictionary override for incident since that field is at task level
If you add it directly in dictionary then it will impact all the tables which use this field.
do what I shared above in screenshots and create new dictionary override record
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2025 09:26 AM
You are pushing 'sys_id' into the array in each case. Don't you want the value of the property instead?
If I read your post correctly, and you want the property value, then you need a comma-delimited string to use in the reference qualifier. To get that, join that array before returning it, or join it in the calling code.
getTableNames: function(chkcategory){
var arr = [];
...
return arr.join(',');
}