jolly-raincoat-49731
12/05/2023, 5:07 PMevents_*
to events_intraday_*
in the queries. Is there an easier way to do that rather than go to each metric or wherever a query is created?billions-xylophone-11752
12/05/2023, 5:27 PMjolly-raincoat-49731
12/05/2023, 5:28 PMjolly-raincoat-49731
12/05/2023, 5:33 PMAND ((_TABLE_SUFFIX BETWEEN '{{date startDateISO "yyyyMMdd"}}' AND '{{date endDateISO "yyyyMMdd"}}') OR
(_TABLE_SUFFIX BETWEEN 'intraday_{{date startDateISO "yyyyMMdd"}}' AND 'intraday_{{date endDateISO "yyyyMMdd"}}'))
jolly-raincoat-49731
12/05/2023, 5:33 PMbillions-xylophone-11752
12/05/2023, 5:43 PMOR
statement should cause problems, but won't there still be the issue of the FROM
clause? I'm pretty sure standard SQL doesn't support the OR
operator in the FROM
clause.billions-xylophone-11752
12/05/2023, 5:44 PMjolly-raincoat-49731
12/05/2023, 6:44 PMbillions-xylophone-11752
12/05/2023, 6:54 PM_intraday
added to the table name). Additionally, we did add support for this recently for any newly created metrics/data sources so it queries both tables at once.
And it just does what you mentioned earlier, of updating the WHERE clause.
WHERE
((_TABLE_SUFFIX BETWEEN '{{date startDateISO "yyyyMMdd"}}' AND '{{date endDateISO "yyyyMMdd"}}') OR
(_TABLE_SUFFIX BETWEEN 'intraday_{{date startDateISO "yyyyMMdd"}}' AND 'intraday_{{date endDateISO "yyyyMMdd"}}'))
We don't have a way to bulk update metric SQL, so they will just have to go through each one and copy/paste this new WHERE clause in.
We are working on our new Fact Tables
and one of the goals of that is to have the common SQL in one place so it's easy to make sweeping changes like this.billions-xylophone-11752
12/05/2023, 6:54 PMjolly-raincoat-49731
12/05/2023, 6:55 PMjolly-raincoat-49731
12/06/2023, 9:40 PMbillions-xylophone-11752
12/06/2023, 9:46 PMjolly-raincoat-49731
12/06/2023, 9:46 PM