boomer77Luna price volatility
    Updated 2021-08-03
    with eth as
    (SELECT
    date_trunc('day', block_timestamp) as date,
    avg(amount) as eth,
    avg(amount_usd) as usd,
    symbol,
    usd/eth as eth_price
    from
    ethereum.udm_events
    where amount is not null and amount_usd is not null and symbol = 'ETH' and date < CURRENT_DATE
    group by 1,4),

    luna as
    (SELECT
    date_trunc('day',block_timestamp) as days, avg(event_amount) as amt, avg(event_amount_usd) as usd, usd/amt as LUNA_price
    from terra.transfers
    where event_currency = 'LUNA'
    group by 1)

    select
    A.date, A.eth_price, B.LUNA_price
    from eth A
    join luna B on A.date = B.days
    where date >= CURRENT_DATE - 15
    order by 1
    Run a query to Download Data