dbt-databricks icon indicating copy to clipboard operation
dbt-databricks copied to clipboard

Support for the `USE_SCHEMA` grant type using the `+grants` model config

Open nihil0 opened this issue 1 year ago • 3 comments

Describe the feature

Databricks Unity Catalog requires that the USE_SCHEMA grant be applied to the parent schema without which grants applied to a model have no effect. Currently dbt does not support the USE_SCHEMA grant type in the +grants: model config. I would like to be able to change the behaviour of +grants such that it automatically applies USE_SCHEMA to the parent schema of that model.

Describe alternatives you've considered

We currently use a macro that applies USE_SCHEMA to all the schemas created as part of the dbt run using a post hook. This is a bit inelegant.

Who will this benefit?

This would benefit everyone working with Databricks unity catalog who is handling grants using dbt.

Are you interested in contributing this feature?

I would like to implement this feature, but I don't know where to get started. Is this something that should be a part of this repo? Or dbt-spark?

nihil0 avatar Mar 10 '23 09:03 nihil0

This issue has been marked as Stale because it has been open for 180 days with no activity. If you would like the issue to remain open, please remove the stale label or comment on the issue.

github-actions[bot] avatar Sep 07 '23 01:09 github-actions[bot]

Marking this as a bug, since it sounds like the grants functionality doesn't work as expected in UC without USE SCHEMA

benc-db avatar Sep 13 '23 18:09 benc-db

This issue has been marked as Stale because it has been open for 180 days with no activity. If you would like the issue to remain open, please remove the stale label or comment on the issue.

github-actions[bot] avatar Mar 12 '24 01:03 github-actions[bot]