-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enable authorization of materialized views #788
base: main
Are you sure you want to change the base?
Conversation
An unrelated integration test fails. My changes didn't alter the behavior tested by the integration test |
@amychen1776 as you requested, I moved my former PR in dbt-bigquery here 1.5 weeks ago. May I ask you or someone in your team to review this PR please? Thank you in advance. |
Thank you @kubikb 🙏 I'll put it in our triage rotation |
@amychen1776 @colin-rogers-dbt @mikealfare sorry for the ping again, but this has been open for some time and this feature is badly needed by a large customer of ours. Can you please review and merge? |
resolves #773.
Problem
Similarly to BigQuery views, BigQuery materialized views can also be authorized to access the data in another dataset(s). However, providing the
grant_access_to
configuration to a model withmaterialized_view
materialization goes silently ignored and the materialized view does NOT get authorized to access data in another dataset. With models withview
materialization, thegrant_access_to
configuration leads to the desired behavior, namely the view gets authorized to access data in another dataset.Solution
This pull request add logic to handle the config
grant_access_to
also for models with materializationmaterialized_view
. The PR also extends currently existing tests.Checklist
Moved from dbt-labs/dbt-bigquery#1470