SocioCryptotx fee vs TPS
    Updated 2023-04-13
    select * from
    (SELECT 'NEAR' as label,
    'NEAR' as sub_label,
    date_trunc('day',block_timestamp) as date,
    avg(TRANSACTION_FEE)/pow(10,24) as daily_avg_fee
    FROM near.core.fact_transactions
    WHERE date between CURRENT_DATE-30 and CURRENT_DATE-1
    GROUP BY date
    UNION
    SELECT 'Polygon' as label,
    'L1' as sub_label,
    date_trunc('day',block_timestamp) as date,
    avg(tx_fee) as daily_avg_fee
    FROM polygon.core.fact_transactions
    WHERE date between CURRENT_DATE-30 and CURRENT_DATE-1
    GROUP BY DATE
    UNION
    SELECT 'Ethereum' as label,
    'L1' as sub_label,
    date_trunc('day',block_timestamp) as date,
    avg(tx_fee) as daily_avg_fee
    FROM ethereum.core.fact_transactions
    WHERE date between CURRENT_DATE-30 and CURRENT_DATE-1
    GROUP BY DATE
    UNION
    SELECT 'Solana' as label,
    'L1' as sub_label,
    date_trunc('day',block_timestamp) as date,
    avg(fee)/pow(10,9) as daily_avg_fee
    FROM solana.core.fact_transactions
    WHERE date between CURRENT_DATE-30 and CURRENT_DATE-1
    GROUP BY DATE
    UNION
    SELECT 'BSC' as label,
    'L1' as sub_label,
    date_trunc('day',block_timestamp) as date,
    Run a query to Download Data