adriaparcerisasWho's Escaping FTX? 2
Updated 2023-04-13
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
t1 as (
SELECT
trunc(block_timestamp,'day') as dates, to_address as wallet
FROM ethereum.core.ez_token_transfers
join ethereum.core.dim_labels on address = from_address
WHERE label like '%alameda%' or label = 'ftx'
AND block_timestamp >= CURRENT_DATE-INTERVAL '1 MONTH'
),
t2 as (
select
trunc(block_timestamp,'day') as date,
count(distinct origin_from_address) as wallets,
sum(wallets) over (order by date) as cum_wallets,
count(distinct tx_hash) as txs,
sum(txs) over (order by date) as cum_txs
from arbitrum.core.fact_token_transfers x
join t1 y on x.origin_from_address = y.wallet
where origin_to_address in ('0x3d6ba331e3d9702c5e8a8d254e5d8a285f223aba','0xb87a436b93ffe9d75c5cfa7bacfff96430b09868')
and from_address <> '0x0000000000000000000000000000000000000000' and date >= CURRENT_DATE-INTERVAL '1 MONTH'
group by 1
),
t3 as (
select
trunc(block_timestamp,'day') as date,
count(distinct origin_from_address) as wallets,
sum(wallets) over (order by date) as cum_wallets,
count(distinct tx_hash) as txs,
sum(txs) over (order by date) as cum_txs
from polygon.core.fact_token_transfers x
join t1 y on x.origin_from_address = y.wallet
where origin_to_address in ('0xd8d177efc926a18ee455da6f5f6a6cfcee5f8f58','0x65187fec6ecc4774c1f632c7503466d5b4353db1','0xf8a140db8b05bec52c7e86d0d40d72f8e54fe559')
and contract_address = '0x8f3cf7ad23cd3cadbd9735aff958023239c6a063'
and from_address <> '0x0000000000000000000000000000000000000000' and date >= CURRENT_DATE-INTERVAL '1 MONTH'
group by 1
),
Run a query to Download Data