Skip to content
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

dbt_utils.get_column_values returns error when "values" is a reserved word #972

Open
4 tasks
rfeith2 opened this issue Dec 12, 2024 · 0 comments
Open
4 tasks
Labels
bug Something isn't working triage

Comments

@rfeith2
Copy link

rfeith2 commented Dec 12, 2024

Describe the bug

When using dbt_utils.get_column_values and the target system treats values as a reserved word an error is returned.

Steps to reproduce

Target = Dremio Cloud

Create Model using dbt_utils.get_column_values

Deploy model

Runtime error is returned

Expected results

Model should deploy without error.

Actual results

Runtime error in model is returned.

Screenshots and log output

System information

The contents of your packages.yml file:
Unable to specify

Which database are you using dbt with?

  • postgres
  • redshift
  • bigquery
  • snowflake
  • [X ] other (specify: Dremio)

The output of dbt --version:

1.7

Additional context

To resolve issue, modify line 37 in dbt-utils/macros/sql/get_column_values.sql

Current:
{{ column }} as value

Change to:
{{ column }} as "value"

Are you interested in contributing the fix?

Happy to create a PR for this.

@rfeith2 rfeith2 added bug Something isn't working triage labels Dec 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working triage
Projects
None yet
Development

No branches or pull requests

1 participant