Hessish aavekashi - lendrs status
Updated 2023-03-01
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 stbl as (select DISTINCT TOKEN_ADDRESS as x, SYMBOL as token0 , avg(price) as pr
from ethereum.core.fact_hourly_token_prices
where HOUR::date >= '2023-01-01'
GROUP by 1,2
having pr between '0.99'and '1.01') ,
lendaave as
(select DISTINCT DEPOSITOR_ADDRESS as wallet1
from ethereum.aave.ez_deposits join stbl on token0=SYMBOL
where BLOCK_TIMESTAMP >= '2023-01-01') ,
lendcomp as
(select DISTINCT SUPPLIER as wallet2
from ethereum.compound.ez_deposits
join stbl on SUPPLIED_SYMBOL=TOKEN0
WHERE BLOCK_TIMESTAMP::date >= '2023-01-01') ,
borraave as
(select DISTINCT BORROWER_ADDRESS as wallet3
from ethereum.aave.ez_borrows
where BLOCK_TIMESTAMP >= '2023-01-01') ,
borrcomp as
(select DISTINCT BORROWER as wallet4
from ethereum.compound.ez_borrows
WHERE BLOCK_TIMESTAMP::date >= '2023-01-01')
select count(DISTINCT wallet1) as users, 'Aave lenders' as t
from lendaave
where wallet1 not in (select DISTINCT wallet2 from lendcomp)
Run a query to Download Data