Skip to content
Discussion options

You must be logged in to vote

Hi @lorogno and thanks for reaching out!

You can always call the datavault4dbt hash macros to hash whatever you want wherever you want.

In an example business satellite this could look the following:

{%- set hash_config_yaml -%}
hd_customer_bs:
    is_hashdiff: true
    columns:
      - original_col_1
      - original_col_2
      - calculated_col_1
      - calculated_col_2
{%- endset -%}

{% set hash_config_dict = fromyaml(hash_config_yaml) %}

WITH 

calculations as (
    SELECT
        hk_customer_h,
        ldts,
        original_col_1,
        original_col_2,
        (original_col_1 + original_col_2) as calculated_col_1,
        (original_col_1 / original_col_2) as calculated_col_2
  …

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by lorogno
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants