- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-21-2025 05:32 AM
Hello team,
I wanted to learn how category and subcategory is auto populating in cmdb_ci records....can someone please help me out?
When i checked in dictionary of those attributes then i found it as "Use dynamic value" was checked as "true" and under dynamic filter option this "gs.include("CMDBItem");var item = new CMDBItem(current);item.setCategory();" script was return.
can you please help out in understanding this script and what happens if i disable it?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-21-2025 06:07 AM
Hi,
The script include CMDBItem based on data from the cmdb_categories table. For example, a windows server (cmdb_win_server) has a category of Hardware, and a SubCategory of Computer.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
the question would be why would they do this?
This is affecting my integration which populated the category for CIs.
I don't want servicenow to decide this for us.
How should we proceed then?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
The value is only set as a default value, so overriding it on insert/update is possible by specifying the value. SN do this, to ensure all CI records have a value in these fields irrespective of whether a company is using them. It allows for consistency in data