Skip to content

Commit

Permalink
Limit window to test eho reconciliation (#92)
Browse files Browse the repository at this point in the history
typo
  • Loading branch information
amishas157 authored Sep 16, 2024
1 parent ee678ca commit b62ec0a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/eho_by_ops.sql
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,13 @@ WITH find_missing AS (
-- Scan only the last 24 hours of data. Alert runs intraday so failures
-- are caught and resolved quickly.
AND TIMESTAMP(op.batch_run_date) >= TIMESTAMP_SUB('{{ dbt_airflow_macros.ts(timezone=none) }}', INTERVAL 1 DAY )
AND TIMESTAMP(op.batch_run_date) < TIMESTAMP_SUB('{{ dbt_airflow_macros.ts(timezone=none) }}', INTERVAL 1 HOUR )
),
find_max_batch AS (
SELECT MAX(batch_run_date) AS max_batch
FROM {{ ref('stg_history_operations') }}
WHERE TIMESTAMP(batch_run_date) >= TIMESTAMP_SUB('{{ dbt_airflow_macros.ts(timezone=none) }}', INTERVAL 1 DAY )
AND TIMESTAMP(batch_run_date) < TIMESTAMP_SUB('{{ dbt_airflow_macros.ts(timezone=none) }}', INTERVAL 1 HOUR )
)
SELECT batch_run_date,
batch_id,
Expand Down

0 comments on commit b62ec0a

Please sign in to comment.