Eman-RazVolume of Interchain Transfers By Route Over Time
Updated 2024-08-01
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
›
⌄
with tab1 as (select date_trunc('day',created_at) as "Date", sum(amount) as "Volume ($DACKIE)",
call:chain || '➡' || call:returnValues:destinationChain as "Route"
from axelar.axelscan.fact_gmp
where call ilike '%0xb5fb4be02232b1bba4dc8f81dc24c26980de9e3c%'
and (data:executed:receipt:logs[1]:address='0xc2bc7a73613b9bd5f373fe10b55c59a69f4d617b' or
data:executed:receipt:logs[1]:address='0x47c337bd5b9344a6f3d6f58c474d9d8cd419d8ca')
group by 1,3),
tab2 as (select hour::date as "Date", avg(price) as avg_price
from crosschain.price.ez_prices_hourly
where token_address='0xc2bc7a73613b9bd5f373fe10b55c59a69f4d617b'
group by 1
order by 1)
select DATE_TRUNC('{{Time_Frame}}',tab1."Date") as "Date", SUM("Volume ($DACKIE)") AS "Volume ($DACKIE)",
SUM("Volume ($DACKIE)"*avg_price) as "Volume ($USD)", "Route"
FROM TAB1 LEFT JOIN TAB2 ON TAB1."Date"=tab2."Date"
where tab1."Date" between '{{Start_Date}}' and '{{End_Date}}'
GROUP BY 1,4
order by 1
Auto-refreshes every 24 hours
QueryRunArchived: QueryRun has been archived