Skip to content

Commit

Permalink
Merge pull request #61 from ggmblr/solve_get_relation_amiguity_issue
Browse files Browse the repository at this point in the history
Changed the identifier argument from name to identifier
  • Loading branch information
fivetran-jamie authored Sep 7, 2022
2 parents 929482a + 106d335 commit 9f89183
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 3 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# dbt_fivetran_log v0.6.3
## Fixes
- Modified the argument used for the identifier in the get_relation macro used in the does_table_exist macro from name to identifier. This avoids issues on snowflake where the name of a table defined in a source yaml may be in lowercase while in snowflake it is uppercased.
## Contributors
- [@ggmblr](https://github.com/ggmblr) ([#60](https://github.com/fivetran/dbt_fivetran_log/pull/60))

# dbt_fivetran_log v0.6.2
## Fixes
- Extend model disablement with `config: is_enabled` setting in sources to avoid running source freshness when a model is disabled. ([#58](https://github.com/fivetran/dbt_fivetran_log/pull/58))
Expand Down
2 changes: 1 addition & 1 deletion dbt_project.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
config-version: 2

name: 'fivetran_log'
version: '0.6.2'
version: '0.6.3'

require-dbt-version: [">=1.0.0", "<2.0.0"]

Expand Down
2 changes: 1 addition & 1 deletion integration_tests/dbt_project.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: 'fivetran_log_integration_tests'
version: '0.6.2'
version: '0.6.3'
config-version: 2
profile: 'integration_tests'

Expand Down
2 changes: 1 addition & 1 deletion macros/does_table_exist.sql
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
{%- set source_relation = adapter.get_relation(
database=node.database,
schema=node.schema,
identifier=node.name ) -%}
identifier=node.identifier ) -%}
{%- if source_relation == None and node.name | lower == table_name | lower -%}
{{ return(False) }} -- return false if relation identified by the database.schema.identifier does not exist for the given table name
{%- elif source_relation != None and node.name | lower == table_name | lower -%}
Expand Down

0 comments on commit 9f89183

Please sign in to comment.