LordkingUniswap - 5. Uniswap on Polygon: Which Bridge to Where?1
Updated 2022-03-17Copy 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
25
26
27
28
›
⌄
with
bridge as (
select
ADDRESS,PROJECT_NAME
from crosschain.address_labels
where BLOCKCHAIN='ethereum' and LABEL_SUBTYPE='bridge'
),
uni_user as (
select
ORIGIN_ADDRESS as uuser,
date_trunc('day',block_timestamp) as date
from ethereum.udm_events
where (to_label ilike'%uniswap%' or from_label ilike'%uniswap%') and block_timestamp::date > current_date-30
group by 1,2
),
bridge_user as (
select bridge.PROJECT_NAME as platform,
ORIGIN_ADDRESS as buser,
date_trunc('day',block_timestamp) as date
from bridge inner join ethereum.udm_events as ue
on (ue.FROM_ADDRESS = bridge.ADDRESS or ue.to_ADDRESS = bridge.ADDRESS )
where block_timestamp::date > current_date-30
group by 1,2,3
)
select count(distinct uuser) as uni_user ,date
from uni_user
group by 2
Run a query to Download Data