-
Notifications
You must be signed in to change notification settings - Fork 207
Open
Labels
feature:grantsIssues related to dbt's grants functionalityIssues related to dbt's grants functionalityfeature:quotingIssues related to dbt's quoting behaviorIssues related to dbt's quoting behaviortype:enhancementNew feature requestNew feature request
Description
Is this a new bug in dbt-core?
- I believe this is a new bug in dbt-core
- I have searched the existing issues, and I could not find an existing issue for this bug
Current Behavior
When grants are setup in an incremental model dbt attempts to run some a REVOKE statement. When the username(s) that currently have access to that table contain a dot character (eg. ivan.sabik), which is completely valid for a Redshift username , building those models fails with:
syntax error at or near "."
That would be solved by adding quotes to those users, that is instead of revoke select on table eventview from ivan.sabik it should be revoke select on table eventview from "ivan.sabik"
Expected Behavior
REVOKE statements don't throw a syntax error
Steps To Reproduce
- Create a username containing a dot character
- Run an incremental dbt model
- Manually add GRANT statements for the user from step 1
- Add a grant configuration in dbt for this model
- Re-run the model
- Confirm you get an error:
syntax error at or near "."
Relevant log output
No response
Environment
- OS:
- Python:
- dbt:Which database adapter are you using with dbt?
redshift
Additional Context
No response
Metadata
Metadata
Assignees
Labels
feature:grantsIssues related to dbt's grants functionalityIssues related to dbt's grants functionalityfeature:quotingIssues related to dbt's quoting behaviorIssues related to dbt's quoting behaviortype:enhancementNew feature requestNew feature request