iboo-jbj2MVDaily minted LUNA
    Updated 2022-04-24
    WITH burned_ust AS (
    SELECT date_trunc('day',block_timestamp) dayt1
    ,SUM(offer_amount) daily_burned_ust
    FROM terra.swaps
    WHERE offer_currency = 'UST'
    AND ask_currency = 'LUNA'
    AND block_timestamp >= '2022-01-01'
    GROUP BY 1
    )
    ,luna_prices AS (
    SELECT date_trunc('day', block_timestamp) dayt2
    ,AVG(price_usd) as average_luna_price_usd
    FROM terra.oracle_prices
    WHERE currency = 'uluna'
    GROUP BY 1
    )
    SELECT dayt1
    ,daily_burned_ust/average_luna_price_usd AS daily_mint_luna
    FROM burned_ust
    JOIN luna_prices
    ON dayt1 = dayt2
    WHERE dayt1 >= '2022-01-01'

    Run a query to Download Data