Alexaypol daily
Updated 2022-10-16Copy Reference Fork
99
1
2
3
4
5
6
7
8
9
10
11
12
›
⌄
select date_trunc('day',block_timestamp) as date, count(distinct tx_hash) as swaps, count(distinct origin_from_address) as users,
case when origin_to_address='0x1b02da8cb0d097eb8d57a175b88c7d8b47997506' then 'SushiSwap'
when (origin_to_address='0xe592427a0aece92de3edee1f18e0157c05861564' or origin_to_address='0x68b3465833fb72a70ecdf485e0e4c7bd8665fc45')
then 'Uniswap'
end as platform
from polygon.core.fact_event_logs
where (origin_to_address='0xe592427a0aece92de3edee1f18e0157c05861564' -- Uniswap V3: Router
or origin_to_address='0x68b3465833fb72a70ecdf485e0e4c7bd8665fc45' -- Uniswap V3: Router 2
or origin_to_address='0x1b02da8cb0d097eb8d57a175b88c7d8b47997506') --SushiSwap: Router
and tx_status='SUCCESS'
group by date, platform
order by date
Run a query to Download Data