Skip to content

Commit

Permalink
update macro name and follow pattern from other use cases
Browse files Browse the repository at this point in the history
* changed macro `dbt_spark_tblproperties_clause()` to `spark__tblproperties_clause()`
* create new macro `tblproperties_clause()` which references the above
  • Loading branch information
etheleon authored and wesleygoi-liftoff committed Aug 3, 2023
1 parent c4a3b8b commit f017a0b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion dbt/include/spark/macros/adapters.sql
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
{% macro dbt_spark_tblproperties_clause() -%}
{% macro tblproperties_clause() %}
{{ return(adapter.dispatch('tblproperties_clause', 'dbt')()) }}
{%- endmacro -%}

{% macro spark__tblproperties_clause() -%}
{%- set tblproperties = config.get('tblproperties') -%}
{%- if tblproperties is not none %}
tblproperties (
Expand Down
2 changes: 1 addition & 1 deletion dbt/include/spark/macros/materializations/seed.sql
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
{{ clustered_cols(label="clustered by") }}
{{ location_clause() }}
{{ comment_clause() }}
{{ dbt_spark_tblproperties_clause() }}
{{ tblproperties_clause() }}
{% endset %}

{% call statement('_') -%}
Expand Down

0 comments on commit f017a0b

Please sign in to comment.