Skip to content

Instantly share code, notes, and snippets.

@cnolanminich
Created April 11, 2024 23:30
Show Gist options
  • Save cnolanminich/3cc7adf64c85370bd06e397b78b92ab5 to your computer and use it in GitHub Desktop.
Save cnolanminich/3cc7adf64c85370bd06e397b78b92ab5 to your computer and use it in GitHub Desktop.
singular dbt test with more than 1 ref with config needed
{{ config(
severity = 'warn',
meta = {
'dagster': {
'ref': {
'name': 'orders_cleaned'
}
}
}
)
}}
SELECT
o.user_id,
o.dt,
o.order_total
FROM {{ ref('orders_cleaned') }} as o
inner join {{ref('users_cleaned')}} as u on u.user_id = users_cleaned.user_id
WHERE order_total <= 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment