SpiltadavidDYDX transfers(amount)
Updated 2023-01-25
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
›
⌄
with cex as (select ADDRESS from ethereum.core.dim_labels
where LABEL_TYPE = 'cex')
select BLOCK_TIMESTAMP::date date,
count(case when ORIGIN_FROM_ADDRESS = ADDRESS then 1 end) from_cex_count,
count(case when ORIGIN_TO_ADDRESS = ADDRESS then 1 end) to_cex_count,
sum(case when ORIGIN_FROM_ADDRESS = ADDRESS then AMOUNT end) from_cex_AMOUNT,
sum(case when ORIGIN_to_ADDRESS = ADDRESS then AMOUNT end) to_cex_AMOUNT,
sum(case when ORIGIN_FROM_ADDRESS = ADDRESS then AMOUNT_USD end) from_cex_AMOUNT_usd,
sum(case when ORIGIN_to_ADDRESS = ADDRESS then AMOUNT_USD end) to_cex_AMOUNT_usd,
count(*) number_of_transfers
from ethereum.core.ez_token_transfers
join cex on address = ORIGIN_FROM_ADDRESS or address = ORIGIN_TO_ADDRESS
where CONTRACT_ADDRESS = '0x92d6c1e31e14520e676a687f0a93788b716beff5'
and BLOCK_TIMESTAMP::date > CURRENT_DATE() - 60
group by 1
order by 1
Run a query to Download Data