What This Table Is
The cmdb_ci table serves as the abstract base for all Configuration Items in ServiceNow's CMDB. It defines the core attributes shared by every CI — identification, operational state, lifecycle tracking, and relationship capabilities. This table establishes the foundational structure that enables ServiceNow to model your entire IT infrastructure as interconnected configuration items.
Owned by the Configuration Management Database (CMDB) module, this table supports the complete ITIL configuration management process — from CI discovery and registration through change impact analysis and relationship mapping. The CMDB process relies on accurate CI data to enable change management, incident resolution, and service impact analysis across your IT infrastructure.
The cmdb_ci table extends the cmdb table and is extended by over 100 specialized CI classes including cmdb_ci_server, cmdb_ci_appl, cmdb_ci_database, and cmdb_ci_service. Each child class inherits the base CI attributes while adding class-specific fields relevant to that configuration item type. This inheritance hierarchy enables both specialized CI management and unified cross-infrastructure queries.
In large enterprise implementations, the CMDB typically contains 50,000-500,000+ CIs with millions of relationship records. The cmdb_ci table itself may hold 10,000-50,000 records representing CIs that don't fit specialized classes. Query performance depends heavily on proper indexing and filtering by sys_class_name to avoid full table scans across the entire CI hierarchy.
When You'll Script Against This Table
You'll primarily script against cmdb_ci in Business Rules that fire on CI lifecycle events, Script Includes handling cross-CI-class operations, and Scheduled Jobs performing bulk CI maintenance. Discovery and Integration Hub flows frequently update CI records through server-side scripts. Background Scripts are common for data cleanup and mass CI updates during CMDB health initiatives.
The itil role provides basic CMDB read access, while cmdb_admin enables full CI management. The discovery_admin role is required for automated CI creation and updates. ACL enforcement varies by CI class, with some sensitive CIs requiring elevated permissions even for read access.
Common scripting patterns:
- Bulk CI state transitions during maintenance windows or decommissioning projects
- Cross-reference validation between CIs and other ITSM tables (incidents, changes, requests)
- Assignment group propagation from CIs to related incidents and changes
- CI attribute synchronization from external data sources and discovery tools
- CMDB health scoring and duplicate CI identification through automated analysis
- Service impact analysis by traversing CI relationships during incident management
- Automated CI lifecycle management based on deployment status and usage metrics
Table Gotchas
Never query cmdb_ci directly in production without filtering by sys_class_name. Without this filter, you'll scan the entire CI inheritance hierarchy causing severe performance issues.
The operational_status field uses integer values, not choice labels. Use getDisplayValue() or check the choice list definition before hardcoding status comparisons.
- The
install_statusfield represents the CI's lifecycle stage whileoperational_statusrepresents its current operational state — many developers confuse these two concepts - CI relationships are stored in separate tables (
cmdb_rel_ci), not as reference fields on the CI record itself — use relationship APIs for traversal
The support_group and assignment_group fields don't automatically inherit from parent CIs. You must implement Business Rules if you want group inheritance behavior.
- Discovery processes can create duplicate CIs if identification rules aren't properly configured — always implement CI reconciliation logic in discovery Business Rules
- Queries joining CIs with incidents or changes should use indexed fields like
sys_idrather thannameto avoid performance bottlenecks
The company field may be null for CIs discovered automatically. Always null-check before using company-based filtering or reporting.
Enjoying this? Get one deep-dive per week.
Join 1,000+ ServiceNow pros — scripts, GlideRecord patterns, Flow Designer techniques, and career moves. Free.
Related Tables
The cmdb_ci table extends the cmdb table, which provides the foundational structure for all configuration management objects. The cmdb table contains core identification fields and serves as the root for the entire CMDB class hierarchy. When building reports or queries that span multiple CI types, you often query the cmdb table directly to get a unified view.
The cmdb_rel_ci table stores all relationships between configuration items and is constantly queried alongside CI tables for impact analysis and dependency mapping. The task table and its children (incident, change_request, sc_request) frequently reference CIs through cmdb_ci fields, enabling service impact tracking and automated assignment based on CI ownership.
User and group tables (sys_user, sys_user_group) are joined constantly for CI ownership, support group assignments, and approval workflows. The core_company table provides organizational context for multi-tenant CMDB implementations, while cmn_location enables geographic and facility-based CI organization and reporting.