Skip to content

Commit 8787167

Browse files
committed
Changed snapshot logic to apply with dbt core. Possibly fixing an unidentified bug :-)
1 parent 53134ce commit 8787167

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

dbt/include/sqlserver/macros/materializations/snapshot/strategies.sql

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,11 @@
2222
{% for col in check_cols %}
2323
{{ snapshotted_rel }}.{{ col }} != {{ current_rel }}.{{ col }}
2424
or
25-
({{ snapshotted_rel }}.{{ col }} is null) and not ({{ current_rel }}.{{ col }} is null)
25+
(
26+
(({{ snapshotted_rel }}.{{ col }} is null) and not ({{ current_rel }}.{{ col }} is null))
27+
or
28+
((not {{ snapshotted_rel }}.{{ col }} is null) and ({{ current_rel }}.{{ col }} is null))
29+
)
2630
{%- if not loop.last %} or {% endif %}
2731

2832
{% endfor %}

0 commit comments

Comments
 (0)