ArioETH Removed Aave
Updated 2022-09-17Copy Reference Fork
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
Deposited as (
select
BLOCK_TIMESTAMP::date as date,
sum(ISSUED_TOKENS) as ETH_Deposited,
sum(ETH_Deposited) over(order by date) as Cum_ETH_Deposited,
avg(ISSUED_TOKENS) as Avg_deposition,
min(ISSUED_TOKENS) as min_deposition,
max(ISSUED_TOKENS) as max_deposition,
median(ISSUED_TOKENS) as med_deposition,
sum(SUPPLIED_USD) as USD_Eq_deposited,
sum(USD_Eq_deposited) over(order by date) as Cum_USD_Eq_deposited,
count(distinct TX_HASH) as N_Deposited_Tx,
count(distinct DEPOSITOR_ADDRESS) as N_depositors,
ETH_Deposited/N_depositors as Deposition_per_User
from ethereum.aave.ez_deposits
where
BLOCK_TIMESTAMP >= CURRENT_DATE() - {{Period}}
and symbol = 'WETH'
group by 1
),
Withdrawn as (
select
BLOCK_TIMESTAMP::date as date,
sum(WITHDRAWN_TOKENS) as ETH_Withdrawn,
sum(ETH_Withdrawn) over(order by date) as Cum_ETH_Withdrawn,
avg(WITHDRAWN_TOKENS) as Avg_Withdrawn,
min(WITHDRAWN_TOKENS) as min_Withdrawn,
max(WITHDRAWN_TOKENS) as max_Withdrawn,
median(WITHDRAWN_TOKENS) as med_Withdrawn,
sum(WITHDRAWN_USD) as USD_Eq_Withdrawn,
sum(USD_Eq_Withdrawn) over(order by date) as Cum_USD_Eq_Withdrawn,
count(distinct TX_HASH) as N_Withdrawn_Tx,
count(distinct DEPOSITOR_ADDRESS) as N_Withdrawer,
ETH_Withdrawn/N_Withdrawer as Withdrawn_per_User
from ethereum.aave.ez_withdraws
Run a query to Download Data