19-06-2026 1st commit
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
from __future__ import annotations
|
||||
|
||||
import polars as pl
|
||||
from datetime import date, datetime, timedelta
|
||||
|
||||
from log import log
|
||||
|
||||
@@ -91,9 +92,10 @@ def delete_existing_data(
|
||||
client,
|
||||
table_name,
|
||||
f"""
|
||||
toMonth(visit_date) = {run_date.month}
|
||||
AND toYear(visit_date) = {run_date.year}
|
||||
""",
|
||||
project_id = 40148
|
||||
AND toMonth(visit_date) = toMonth(toDate('2026-06-18'))
|
||||
AND toYear(visit_date) = toYear(toDate('2026-06-18'))
|
||||
""",
|
||||
)
|
||||
|
||||
return
|
||||
@@ -142,7 +144,7 @@ def delete_existing_data(
|
||||
client,
|
||||
table_name,
|
||||
f"""
|
||||
toDate(visit_date) BETWEEN toDate('{run_date - }') AND toDate('{run_date}')
|
||||
toDate(visit_date) BETWEEN toDate('{run_date - timedelta(days=15) }') AND toDate('{run_date}')
|
||||
=
|
||||
""",
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user