Afonso_DiazBy pool
Updated 2024-11-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
›
⌄
with
main as (
select
tx_id,
block_timestamp,
from_address as user,
split(pool_name, '-')[0] as pool_name,
lp_action,
nvl(rune_amount_usd, asset_amount_usd) as amount_usd
from
thorchain.defi.fact_liquidity_actions
where
split(pool_name, '-')[0] in ('AVAX.USDC', 'AVAX.SOL', 'AVAX.AVAX')
and block_timestamp between '{{ start_date }}' and '{{ end_date }}'
)
select
pool_name,
lp_action,
count(distinct tx_id) as transactions,
count(distinct user) as users,
sum(amount_usd) as volume_usd,
avg(amount_usd) as average_amount_usd
from
main
group by 1, 2
order by 1, 2
QueryRunArchived: QueryRun has been archived