Mity total borrower
Updated 2023-04-21
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
›
⌄
select count(distinct EVENT_INPUTS:borrower)as total_unique_borrower,
case
when CONTRACT_ADDRESS='0xc22f01ddc8010ee05574028528614634684ec29e'then 'AVAX total unique borrower'
when CONTRACT_ADDRESS='0x8b650e26404ac6837539ca96812f0123601e4448'then 'USDT total unique borrower'
when CONTRACT_ADDRESS='0x929f5cab61dfec79a5431a7734a68d714c4633fa'then 'WETH total unique borrower'
when CONTRACT_ADDRESS='0xed6aaf91a2b084bd594dbd1245be3691f9f637ac'then 'USDC total unique borrower'
when CONTRACT_ADDRESS='0x585e7bc75089ed111b656faa7aeb1104f5b96c15'then 'LINK total unique borrower'
when CONTRACT_ADDRESS='0xc988c170d0e38197dc634a45bf00169c7aa7ca19'then 'DAI total unique borrower'
when CONTRACT_ADDRESS='0x3fe38b7b610c0acd10296fef69d9b18eb7a9eb1f'then 'WBTC total unique borrower' end as total_borrower
from avalanche.core.fact_event_logs
where EVENT_NAME='Borrow'
and TX_STATUS='SUCCESS'
and total_borrower is not null
group by 2