Is there a SQL media to navigate ServiceNow Database?

michael_garz
Tera Contributor

Good morning all,

I'm trying to perform an aggregation on ServiceNow that would typically be easy to do with SQL, but having a hard time while trying to do with the view/glide record combination.

Is there any way we are able to access a SQL panel, or a connect a SQL client to ServiceNow database to perform SQL queries?

I would like to do somthing like: SELECT user.sys_id , count (role.id) FROM sys_user user LEFT JOIN sys_user_has_role user_role on user.id = role.user_id

I want to effectively see the users the have a role (and how many roles they have) and the ones that have no role.

Also I would like to be able to revert this query (which roles doesn't have users associated to it) and it is not straightfoward otherwise.

 

Many thanks for the support,

Michael

0 REPLIES 0