Skip to main content

vw_group_roles

Creates, updates, deletes, gets or lists a vw_group_roles resource.

Overview

Namevw_group_roles
TypeView
Iddatabricks_workspace.iam.vw_group_roles

Fields

The following fields are returned by this view:

NameDatatypeDescription
deployment_namestringWorkspace deployment name used to scope the query.
idstringUnique identifier for the workspace group.
displayNamestringHuman-readable display name of the workspace group.
rolestringRole assigned to the group (one row per role assignment).

Required Parameters

The following parameters are required by this view:

NameDatatypeDescription
deployment_namestringWorkspace deployment name used to scope the query.

SELECT Examples

SELECT
deployment_name,
id,
displayName,
role
FROM databricks_workspace.iam.vw_group_roles
WHERE deployment_name = '{{ deployment_name }}';

SQL Definition

SELECT
g.deployment_name,
g.id,
g.displayName,
JSON_EXTRACT(r.value, '$.value') AS role
FROM databricks_workspace.iam.groups_v2 g,
JSON_EACH(g.roles) r
WHERE g.deployment_name = '{{ deployment_name }}'