Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add null equality condition to equals macro #744

Merged
merged 49 commits into from
Feb 4, 2025

Conversation

VersusFacit
Copy link
Contributor

@VersusFacit VersusFacit commented Jan 27, 2025

resolves #110
followup to #383 #394

Note: still needs the athena test skip fix to be merged into main

Problem

We need to add the capability for the equals macro to way the presence of no values. However, this is a huge blast radius and doesn't suit all use cases. So we'd like to add it behind a behavior flag and through customer use of this different behavior determine in the future what would be a better long-term solution while also delivering the customer value we need now. A complete solution will require far more investigation outside of this effort.

Solution

The equals macro can be configured at the dbt_project.yml level. Special attention is given to bigquery tests in this poor request because turning this flag on or off results in many errors across our current tests. This macro does not play well with sophisticated partitioning. A follow on snowflake PR is coming that will make use of this behavior and test it even more thoroughly.

Checklist

  • I have read the contributing guide and understand what's expected of me
  • I have run this code in development and it appears to resolve the stated issue
  • This PR includes tests, or tests are not required/relevant for this PR
  • This PR has no interface changes (e.g. macros, cli, logs, json artifacts, config files, adapter interface, etc) or this PR has already received feedback and approval from Product or DX

colin-rogers-dbt pushed a commit that referenced this pull request Feb 3, 2025
@colin-rogers-dbt colin-rogers-dbt merged commit a9a0926 into main Feb 4, 2025
97 checks passed
@colin-rogers-dbt colin-rogers-dbt deleted the add_null_equality_condition_to_equals_macro branch February 4, 2025 16:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla:yes The PR author has signed the CLA
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants