Sbhn_NPShare of DEXs
Updated 2022-09-29
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
›
⌄
--credit : 0xHaM☰d
with miner as (
select
DISTINCT miner
from ethereum.core.fact_blocks
where NETWORK='mainnet'
)
-- , swap as (
SELECT
'Selling ETH' as act,
count(DISTINCT tx_hash) as swap_tx_cnt,
count(DISTINCT SENDER) as uniq_swapper,
sum(amount_in) as swap_eth_amt
FROM ethereum.core.ez_dex_swaps
WHERE SYMBOL_IN = 'WETH'
AND BLOCK_NUMBER >= 15537351 -- 15,537,351 The merg block number
UNION ALL
SELECT
'Buying ETH' as act,
count(DISTINCT tx_hash) as swap_tx_cnt,
count(DISTINCT SENDER) as uniq_swapper,
sum(amount_out) as swap_eth_amt
FROM ethereum.core.ez_dex_swaps
WHERE SYMBOL_OUT = 'WETH'
AND BLOCK_NUMBER >= 15537351 -- 15,537,351 The merg block number
UNION ALL
SELECT
'Miner Selling ETH' as act,
count(DISTINCT tx_hash) as swap_tx_cnt,
count(DISTINCT SENDER) uniq_swapper,
sum(amount_in) as swap_eth_amt
FROM ethereum.core.ez_dex_swaps
Run a query to Download Data