MoDeFiOptimism - OPtimitic or Pessimistic 3
Updated 2022-10-19Copy Reference Fork
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
›
⌄
with arbi as (
select date_trunc(day,BLOCK_TIMESTAMP) as date, count(*) as arbi_transfers, count(distinct ORIGIN_FROM_ADDRESS) as arbi_sender
from arbitrum.core.fact_token_transfers
where BLOCK_TIMESTAMP::date>=CURRENT_DATE-90
group by date),
opti as (
select date_trunc(day,BLOCK_TIMESTAMP) as date, count(*) as opti_transfers, count(distinct ORIGIN_FROM_ADDRESS) as opti_sender
from optimism.core.fact_token_transfers
where BLOCK_TIMESTAMP::date>=CURRENT_DATE-90
group by date),
poly as (
select date_trunc(day,BLOCK_TIMESTAMP) as date, count(*) as poly_transfers, count(distinct ORIGIN_FROM_ADDRESS) as poly_sender
from polygon.core.fact_token_transfers
where BLOCK_TIMESTAMP::date>=CURRENT_DATE-90
group by date)
select a.date, arbi_transfers, opti_transfers, poly_transfers, arbi_sender, opti_sender, poly_sender
from arbi a
join opti b
on a.date=b.date
join poly c
on a.date=c.date
Run a query to Download Data