KaskoazulPleasure to burn
Updated 2022-02-26
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 LUNA AS (
SELECT
block_timestamp::date AS fecha,
sum(event_attributes:amount[0]:amount/pow(10,6)) AS LUNA_BURNT,
sum(LUNA_BURNT) OVER (ORDER BY fecha) AS LUNA_BURNT_CUMULATIVE
FROM
terra.msg_events
WHERE
event_type = 'burn'
AND event_attributes:amount[0]:denom = 'uluna'
AND fecha >= CURRENT_DATE - 30
GROUP BY 1
ORDER BY 1
),
UST AS (
SELECT
date as fecha,
sum(balance) as UST_SUPPLY
FROM
terra.daily_balances
WHERE
currency = 'UST'
AND fecha >= CURRENT_DATE - 30
AND balance > 0
AND balance_type = 'liquid'
GROUP BY 1
ORDER BY 1
)
SELECT
l.fecha,
l.LUNA_BURNT,
l.LUNA_BURNT_CUMULATIVE,
u.UST_SUPPLY,
u.UST_SUPPLY - 12437193962.9145 as UST_SUPPLY_CHANGE
Run a query to Download Data