Skip to content

Commit

Permalink
Small hack to workaround BigQuery
Browse files Browse the repository at this point in the history
  • Loading branch information
clrcrl committed Apr 5, 2021
1 parent c1709ef commit f669d93
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions macros/schema_tests/sequential_values.sql
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,11 @@ validation_errors as (
select
*
from windowed
where not({{ column_name }} =
{% if datepart %}
{{ dbt_utils.dateadd(datepart, interval, 'previous_' + column_name) }}
where not(cast({{ column_name }} as timestamp)= cast({{ dbt_utils.dateadd(datepart, interval, 'previous_' + column_name) }} as timestamp))
{% else %}
previous_{{ column_name }} + {{ interval }}
where not({{ column_name }} = previous_{{ column_name }} + {{ interval }})
{% endif %}
)
)

select
Expand Down

0 comments on commit f669d93

Please sign in to comment.