permissions
Operations on a permissions
resource.
Overview
Name | permissions |
Type | Resource |
Id | databricks_workspace.dbsql.permissions |
Fields
Name | Datatype |
---|---|
access_control_list | array |
object_id | string |
object_type | string |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
get | SELECT | objectId, objectType, deployment_name | Gets a JSON representation of the access control list (ACL) for a specified object. |
set | REPLACE | objectId, objectType, deployment_name | Sets the access control list (ACL) for a specified object. This operation will complete rewrite the ACL. |
transferownership | EXEC | objectType, deployment_name | Transfer ownership of a single object. |
SELECT
examples
SELECT
access_control_list,
object_id,
object_type
FROM databricks_workspace.dbsql.permissions
WHERE objectId = '{{ objectId }}' AND
objectType = '{{ objectType }}' AND
deployment_name = '{{ deployment_name }}';
REPLACE
example
Replaces a permissions
resource.
/*+ update */
-- replace field1, field2, etc. with the fields you want to update
REPLACE databricks_workspace.dbsql.permissions
SET field1 = '{ value1 }',
field2 = '{ value2 }', ...
WHERE objectId = '{{ objectId }}' AND
objectType = '{{ objectType }}' AND
deployment_name = '{{ deployment_name }}';