elsina✅ Supply: single number
Updated 2023-04-13
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 all_transfers as (
select
sender as addr,
sum(amount::number/1e6) as volume
from terra.core.ez_transfers
where currency = 'uluna' and amount is not null and tx_succeeded = true-- and message_type = '/ibc.applications.transfer.v1.MsgTransfer'
group by 1
union all
select
receiver as addr,
-sum(amount::number/1e6) as volume
from terra.core.ez_transfers
where currency = 'uluna' and amount is not null and tx_succeeded = true-- and message_type = '/ibc.applications.transfer.v1.MsgTransfer'
group by 1
),
balance as (
select
addr,
sum(volume::number) as wallet_balance
from all_transfers
group by 1 having wallet_balance > 0
),
circulating_supply as (
select sum(wallet_balance) as "Circulating Supply"
from balance
),
rec as (
select
receiver,
sum(amount)/1e4 as rec_vol
from terra.core.ez_transfers
where currency = 'uluna'
group by 1
),
Run a query to Download Data