How can we report on cmdb_items that have no relationship to other cmdb_items?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-23-2015 12:54 AM
How can we report on cmdb_items that have no relationship to other cmdb_items?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-23-2015 05:51 AM
You will need to create a database view [which is very easy] to report against since the CI's and the relationships are held in different underlying tables.
Create a database View:
http://wiki.servicenow.com/index.php?title=Database_Views#gsc.tab=0
I hope this helps!
Marty

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-23-2015 06:15 AM
Hi Veerle,
To do this, you will need a Database View that links the Configuration Items (cmdb_ci or a table that extends it if you wanted to be more specific and just report on something like Servers with no relationships) and the CI Relationship (cmdb_rel_ci) table. Set this up with a left join as described in the blog post How Do You Report on Nothing? and you should be able to find what you want. Once you have the list, you can define some filters so you don't include items (such as end user computers if you have CIs for them) that you do not want to include).
Here is how I configured the Database View:
Some important points here:
- Order is important
- You will need to add the Left join colum to the list to adjust the value to true
- The full Where clause is: rel_parent = ci_sys_id || rel_child = ci_sys_id. This matches where the CI is a child or a parent in the relationship.
When you click Try it, you can update the columns that display and apply a filter to get the information you are looking for. This is what I did:
It becomes a simple list with three fields, and I filtered so it displayed items only when the child and parent were both blank.
Hope this helps.
Ben
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-25-2017 12:28 AM
Hi Ben, when I try to run this DB view the browser window hangs and just shows a blank page. Any idea why this is happening?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-25-2017 06:41 AM
Suhas,
Can you please share a screenshot of your DB View configuration and the screen where you are trying to load it?
We need to determine if there is just no data that matches your configuration or if your configuration is causing an issue that is preventing the load.
Thanks,
Ben