Muzepool info
    Updated 2023-05-01
    -- forked from Daily Swap Count kpi @ https://flipsidecrypto.xyz/edit/queries/62d23b3c-31bd-4c46-91fe-8a17dbb517a5

    -- forked from Daily Volume kpi @ https://flipsidecrypto.xyz/edit/queries/da284f28-404b-49b6-8d40-26ac171824bb

    -- forked from Volume kpi @ https://flipsidecrypto.xyz/edit/queries/e3d504c9-78f3-4995-bc40-b10fd97733d4

    with pricea as (
    select
    recorded_hour::Date as day,
    token as symbol,
    id as token_contract,
    avg( close ) as usdprice

    from flow.core.fact_hourly_prices
    where symbol ilike '{{Token_Symbol_A}}'
    group by 1,2,3
    ),

    priceb as (
    select
    recorded_hour::Date as day,
    token as symbol,
    id as token_contract,
    avg( close ) as usdprice

    from flow.core.fact_hourly_prices
    where symbol ilike '{{Token_Symbol_B}}'
    group by 1,2,3
    ),

    token0 as (
    select
    date, usdprice, swap_contract, Total_USD_Volume, Swappers_Count, Swap_Count
    case
    when Token_In_Contract ilike '%TeleportedTetherToken' then 'Usdt'
    Run a query to Download Data