binhachonSushi during Volatile Times II - Zoom out
Updated 2022-05-31
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
29
30
31
32
33
34
35
36
›
⌄
with polygon_pools as (
select
address
from flipside_prod_db.polygon.labels
where label = 'sushiswap'
and label_subtype = 'pool'
),
transfer_in as (
select
distinct block_timestamp,
tx_id,
from_address as address
from flipside_prod_db.polygon.udm_events
where block_timestamp::date >= '2022-01-01'
and to_address in (select address from polygon_pools)
and event_name = 'transfer'
and amount is not null
),
transfer_out as (
select
distinct block_timestamp,
tx_id,
to_address as address
from flipside_prod_db.polygon.udm_events
where block_timestamp::date >= '2022-01-01'
and from_address in (select address from polygon_pools)
and event_name = 'transfer'
and amount is not null
),
swap_transactions as (
select
distinct transfer_in.*
from transfer_in
inner join transfer_out on (transfer_in.tx_id = transfer_out.tx_id)
),
polygon_stats as (
Run a query to Download Data