Afonso_Diazaave-borrow-mkr-5
Updated 2023-03-09
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
›
⌄
with t as (
select
borrower_address as borrower,
count(distinct tx_hash) as transactions
from ethereum.aave.ez_borrows
where aave_version = 'Aave V2'
and symbol in ('MKR')
group by 1
)
select
case
when transactions = 1 then '1 Transaction'
when transactions < 5 then 'Between 1 - 5 Transactions'
when transactions < 10 then 'Between 5 - 10 Transactions'
when transactions < 100 then 'Between 10 - 100 Transactions'
when transactions < 1000 then 'Between 100 - 1K Transactions'
when transactions < 10000 then 'Between 1K - 10K Transactions'
when transactions < 100000 then 'Between 1K - 100K Transactions'
else 'More than 100K Transactions'
end as type,
count(distinct borrower) as borrowers
from t
group by 1
Run a query to Download Data