-
Notifications
You must be signed in to change notification settings - Fork 15
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
Cannot authorize view in same project but different dataset #21
Comments
Figured out the actual issue. BQ queries no longer requires the ticks around the project.dataset.table when creating views. The current code is looking for the ticks as a valid table and when it is not found the view is not authorized. --works bqva authorize --view project.dataset.viewName --does not works bqva authorize --view project.dataset.viewName_noTick The issue is in the STANDARD_SQL_TABLE_PATTERN:
?(?!\()\b"
|
Hi @pathatcher, thanks for raising this. I've updated the regex pattern used when parsing objects from a view definition to account for the latest BigQuery syntax. I've released a new version on PyPI, if and when you get a chance please give it a try and let me know if it resolves the issue you were having. |
Shoot! So sorry for the super late response. It worked. Again sorry about my slow response |
Name: bigquery-view-analyzer
Version: 20.4.1
Good afternoon. We cannot seem to authorize views that reside in the same project and different datasets. Our users have access to a dataset containing views but do not have direct access to the dataset with the tables. If the dataset is in a different project we are able to authorize without issue.
Thank you
examples
[doesn't work]
bqva tree --view "mtech-daas-transact-pdata-uat:rfnd_sls_v.ebr_ros_arsfmstr_xxpezt_nc_xros115_extract_v"
displays
◉ = Project ◉ = Table
◉ = Dataset ◉ = View
mtech-daas-transact-pdata-uat:rfnd_sls_v.ebr_ros_arsfmstr_xxpezt_nc_xros115_extract_v
[works]
mtech-daas-appdata:cubpmvp.date_dim_v
└── mtech-daas-appdata:ewpmvp.date_dim_v
└── mtech-daas-reference-pdata:trst_ref.DATE_DIM
The text was updated successfully, but these errors were encountered: