SniperDistribution of swappers by number of swaps Cosmos chains via Squid copy
Updated 2024-07-02
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
›
⌄
with
tbl AS (
SELECT
sender,
sum(amount) AS total_volume_swapped,
-- COUNT(DISTINCT tx_hash) as count_TXs,
CASE WHEN total_volume_swapped < 10 then 'Less Than 10 USD'
WHEN total_volume_swapped >= 10 AND total_volume_swapped < 100 then '[$10 - $100)'
WHEN total_volume_swapped >= 100 AND total_volume_swapped < 1000 then '[$100 - $1k)'
WHEN total_volume_swapped >= 1000 AND total_volume_swapped < 10000 then '[$1k - $10k)'
WHEN total_volume_swapped >= 10000 AND total_volume_swapped <= 100000 then '[$10k - $100k]'
ELSE 'More Than 100k USD' END AS type
FROM
axelar.defi.ez_bridge_squid
WHERE
block_timestamp::date>='{{Start_Date}}' and block_timestamp::date<='{{End_Date}}'
GROUP BY 1
)
SELECT
type,
count(DISTINCT t1.sender) AS total_swappers
FROM
axelar.defi.ez_bridge_squid t1 JOIN tbl t2 ON t1.sender = t2.sender
GROUP by 1
QueryRunArchived: QueryRun has been archived