SocioCryptothe average time between blocks
    Updated 2023-04-13
    --Show the average time between blocks over time
    SELECT
    avg(datediff(second, a.block_timestamp,b.block_timestamp)) as avg_time_diff,
    max(datediff(second, a.block_timestamp,b.block_timestamp)) as max_time_diff,
    min(datediff(second, a.block_timestamp,b.block_timestamp)) as min_time_diff
    FROM polygon.core.fact_blocks a, polygon.core.fact_blocks b
    WHERE a.block_number = b.block_number -1
    AND a.block_timestamp::date = current_date -1




    Run a query to Download Data