Skip to content

Files

Latest commit

c6f6f77 · Apr 25, 2025

History

History
48 lines (32 loc) · 1.36 KB
·

File metadata and controls

48 lines (32 loc) · 1.36 KB
·
subcategory
Unity Catalog

databricks_views Data Source

Retrieves a list of view full names in Unity Catalog, that were created by Terraform or manually. Use databricks_tables for retrieving a list of tables.

-> This data source can only be used with a workspace-level provider!

Example Usage

Granting SELECT and MODIFY to sensitive group on all views in a things databricks_schema from sandbox databricks_catalog.

data "databricks_views" "things" {
  catalog_name = "sandbox"
  schema_name  = "things"
}

resource "databricks_grants" "things" {
  for_each = data.databricks_views.things.ids

  table = each.value

  grant {
    principal  = "sensitive"
    privileges = ["SELECT", "MODIFY"]
  }
}

Argument Reference

Attribute Reference

This data source exports the following attributes:

  • ids - set of databricks_view full names: catalog.schema.view

Related Resources

The following resources are used in the same context: