distinct=False)%} {{return(adapter.dispatch('pivot','dbt_utils')(column,values,alias,agg,cmp,prefix,suffix,then_value,else_value,quote_identifiers,distinct)) }} {%endmacro%} {%macrodefault__pivot(column, values, alias=True, agg='sum', cmp='=', prefix='', suffix='', then_value=1,...
distinct=False) %} {{ return(adapter.dispatch('pivot', 'dbt_utils')(column, values, alias, agg, cmp, prefix, suffix, then_value, else_value, quote_identifiers, distinct)) }} {% endmacro %} {% macro default__pivot(column, values, alias=True, agg='sum', cmp='=', prefix='', s...
Learn how dbt-utils enhances dbt with pre-built macros, key features, and practical use cases. Streamline your data transformations with our step-by-step guide. Jun 11, 2024 · 12 min read Contents What is dbt-utils? Key features and functionalities Why Use dbt-utils? dbt-utils Installatio...
Utility functions for dbt projects. Contribute to hui-jie-lim/dbt-utils development by creating an account on GitHub.
version: 2 models: - name: model_name tests: - dbt_utils.fewer_rows_than: compare_model: ref('other_table_name') This test supports the group_by_columns parameter; see Grouping in tests for details. equality (source) Asserts the equality of two relations. Optionally specify a subset of ...
version: 2 models: - name: model_name tests: - dbt_utils.expression_is_true: expression: "col_a + col_b = total" The macro accepts an optional argument where that allows for asserting the expression on a subset of all records. Usage: version: 2 models: - name: model_name tests: ...
version: 2 models: - name: model_name tests: - dbt_utils.fewer_rows_than: compare_model: ref('other_table_name') This test supports the group_by_columns parameter; see Grouping in tests for details. equality (source) Asserts the equality of two relations. Optionally specify a subset of ...
version: 2 models: - name: model_name tests: - dbt_utils.recency: datepart: day field: created_at interval: 1 at_least_one (source) This schema test asserts if column has at least one value. Usage: version: 2 models: - name: model_name columns: - name: col_name tests: - dbt_ut...
version: 2 models: - name: model_name tests: - dbt_utils.equal_rowcount: compare_model: ref('other_table_name') This test supports the group_by_columns parameter; see Grouping in tests for details. fewer_rows_than (source) Asserts that the respective model has fewer rows than the model...
Utility functions for dbt projects. Contribute to dbt-labs/dbt-utils development by creating an account on GitHub.