Would anyone know how I could join two tables and have it appear as one?

abrahams
Kilo Sage

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?

1 ACCEPTED SOLUTION

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.


View solution in original post

6 REPLIES 6

abrahams
Kilo Sage

I discovered that I need to use MySQL syntax. Knowing that I was able to get my query to work.


Sue, what did you do to solve this (what do you mean by you needed "to use MySQL syntax")?


DarrenGeros
Kilo Explorer

eMite is a cloud reporting platform that provides OLAP reporting capability so it provides the ability to join multiple reports together automatically.


jim pisello
Giga Expert

Use Database Views to link multiple tables together. The database view acts as a standalone table that can be reported on, exported, etc.