- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-25-2013 10:34 AM
I have two tables that I would like to join together so that they would appear as one for reporting. One is a ServiceNow table (task_time_worked) and other is a table that we created which also contains time worked. The table we created is a standalone table we created in ServiceNow and is in no way connected to any other ServiceNow table. The two tables contain basically the same information but have no connection to each other. I need to report on time worked regardless on which table the data is stored in.
I can't seem to find any way to do a Union view of the two tables or any way to do a full outer join in ServiceNow's database view tool so I've downloaded the ODBC driver in attempt to accomplish this outside of ServiceNow. The ODBC driver appears to be very restrictive. Normally reporting on two tables like this would be a relatively simple thing to do but I am finding not all SQL statements are allowed with the ServiceNow ODBC driver.
Would anyone know of a way that I could join two unrelated table together for reporting purposes?
Solved! Go to Solution.
- Labels:
-
Service Mapping
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-19-2015 05:47 AM
You can create views in ServiceNow however I don't know of a way to make fields that have similar data in two different tables to behave as one. To get the report to behave as I needed I used an external tool that allowed me to format a report to allow the field in both tables to look as one. The SQL query syntax that I used in the tool was MySQL which is a tiny bit different than SQL Server.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-19-2015 05:47 AM
You can create views in ServiceNow however I don't know of a way to make fields that have similar data in two different tables to behave as one. To get the report to behave as I needed I used an external tool that allowed me to format a report to allow the field in both tables to look as one. The SQL query syntax that I used in the tool was MySQL which is a tiny bit different than SQL Server.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-25-2016 11:55 AM
You can go one level higher in the hierarchy, and use the class field as the filter. So you can join multiple tables for example if you using the cmdb_ci as the reference table , and filtering using the reference qualifier on the class field:
sys_class_name=u_cmdb_ci_service_it^ORsys_class_name=u_cmdb_ci_service_it_portfolio^ORsys_class_name=service_offering^ORsys_class_name=cmdb_ci_business_process