TheLaughingManAll NET Sellers
Updated 2024-07-31Copy Reference Fork
999
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
›
⌄
-- forked from SS Param Overview @ https://flipsidecrypto.xyz/edit/queries/17ff4a7c-ca47-4bf5-aec1-95df92890d7a
with cex_flows as (
with transfers as (
SELECT
-- block_timestamp::date as ddate
-- , PROJECT_NAME
-- , t.to_address as cex_address
from_address as wallet
--sum(eth.amount) as eth_amount,
, sum(amount_usd) as usd_amount
, SUM(AMOUNT_PRECISE) as token_amount
, 'inflow' as side
from arbitrum.core.ez_token_transfers t
inner join arbitrum.core.dim_labels l on t.to_address=l.address
where 1=1
and t.contract_address = lower('0x95146881b86b3ee99e63705ec87afe29fcc044d9')
and l.label_type='cex'
AND block_timestamp between '{{Start_date}}' AND '{{End_date}}'
and l.label_subtype='deposit_wallet'
group by wallet, side --, PROJECT_NAME, CEX_address, wallet, side
UNION
SELECT
-- block_timestamp::date as ddate
-- , PROJECT_NAME
-- , t.from_address as cex_address
to_address as wallet
-- --sum(eth.amount) as eth_amount,
, sum(amount_usd) as usd_amount
, SUM(AMOUNT_PRECISE) as token_amount
, 'outflow' as side
from arbitrum.core.ez_token_transfers t
inner join arbitrum.core.dim_labels l on t.from_address=l.address
where 1=1
QueryRunArchived: QueryRun has been archived