Updated 2022-08-07Copy Reference Fork
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
›
⌄
with optimism as (
select a.block_timestamp::date as date, avg(b.tx_fee) as avg_fee_eth, 'Average Optimisim Tx Fee' as type
from optimism.core.fact_event_logs a left join optimism.core.fact_transactions b on a.tx_hash = b.tx_hash
where a.block_timestamp::date >= '2022-04-01'
and a.event_name = 'Swap'
group by 1
),
ethereum as (
select a.block_timestamp::date as date, avg(b.tx_fee) as avg_fee_eth, 'Average Ethereum Tx Fee' as type
from ethereum.core.ez_dex_swaps a left join ethereum.core.fact_transactions b on a.tx_hash = b.tx_hash
where a.block_timestamp::date >= '2022-04-01'
group by 1
)
select * from optimism
union
select * from ethereum
Run a query to Download Data