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

audit-helper: make commented out sql TSQL compliant #54

Merged
merged 2 commits into from
Jun 25, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## `v0.7.2`

- fix to make the commented out SQL in `audit_helper.compare_queries()` TSQL compatible [#54](https://github.com/dbt-msft/tsql-utils/pull/54)

## `v0.7.1`

### New features
Expand Down
5 changes: 3 additions & 2 deletions macros/dbt_audit_helper/compare_queries.sql
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,9 @@ summary_stats as (

group by in_a, in_b
)
{# use this if you want to see all mismatching rows! #}
-- select * from all_records
-- where not (in_a and in_b)
-- where not (in_a=1 and in_b=1)
-- order by {{ primary_key ~ ", " if primary_key is not none }} in_a desc, in_b desc

select
Expand All @@ -86,4 +87,4 @@ from summary_stats

{% macro synapse__compare_queries(a_query, b_query, primary_key=None) -%}
{% do return( tsql_utils.sqlserver__compare_queries(a_query, b_query, primary_key=None)) %}
{%- endmacro %}
{%- endmacro %}