-- forked from Arbitrum Latency - Historical Avg @ https://flipsidecrypto.xyz/edit/queries/169619c9-09b8-4074-8ad8-d9ca8b2581fb
select
lower(table_name) as table_name,
avg(seconds_behind / 60) as mins_behind
from bi_analytics.core.fact_data_latency
where recorded_timestamp::DATE >= current_date - 3
and chain = 'avalanche'
group by 1
order by 1