--this code is thankfully burrowed from alik110: https://app.flipsidecrypto.com/dashboard/mLcTci
with table1 as (
select hour::date as date,
avg (price) as ETH
from ethereum.core.fact_hourly_token_prices
where symbol in ('WETH')
and hour >= '2022-11-01'
group by 1),
table2 as (
select recorded_hour::date as date,
avg (close) as SOL
from solana.core.fact_token_prices_hourly
where symbol in ('SOL')
and recorded_hour >= '2022-11-01'
group by 1)
select t1.date,
ETH,
SOL
from table1 t1 join table2 t2 on t1.date = t2.date