Skip to content

Commit

Permalink
Merge pull request #11 from VDFaller/main
Browse files Browse the repository at this point in the history
Change dbt_utils.type_XXX to dbt.type_XXX
  • Loading branch information
courentin authored Mar 15, 2023
2 parents 222a85e + 9eddf85 commit 92d795d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion macros/dbt_date/calendar_date/convert_timezones.sql
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{%- macro athena__convert_timezone(column, target_tz, source_tz) -%}
CAST({{ column }} as {{ dbt_utils.type_timestamp() }}) AT TIME ZONE '{{ source_tz }}' AT TIME ZONE '{{ target_tz }}'
CAST({{ column }} as {{ dbt.type_timestamp() }}) AT TIME ZONE '{{ source_tz }}' AT TIME ZONE '{{ target_tz }}'
{%- endmacro -%}
4 changes: 2 additions & 2 deletions macros/dbt_utils/cross_db_utils/hash.sql
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{%- macro hash(field) -%}
{{ return(adapter.dispatch('hash', 'dbt_utils') (field)) }}
{{ return(adapter.dispatch('hash', 'dbt') (field)) }}
{%- endmacro -%}


{%- macro athena__hash(field) -%}
to_hex(sha256(to_utf8(cast({{field}} as {{dbt_utils.type_string()}}))))
to_hex(sha256(to_utf8(cast({{field}} as {{dbt.type_string()}}))))
{%- endmacro -%}

0 comments on commit 92d795d

Please sign in to comment.