hbd1994TPS in Chains
    Updated 2023-09-12
    (with av_tps as (

    select
    (count(distinct tx_id)/(count(distinct date_trunc('second',block_timestamp)))) as avg_tps
    from sei.core.fact_transactions
    where block_timestamp >= '2023-08-15'
    and block_timestamp::date < current_date),

    daily_tp as (
    select
    date(block_timestamp) as date,
    (count(distinct tx_id)/(count(distinct date_trunc('second',block_timestamp)))) as daily_avg_tps
    from sei.core.fact_transactions
    where block_timestamp >= '2023-08-15'
    and block_timestamp::date < current_date
    group by 1)

    select
    'Sei' as "Network",
    date as "Date",
    daily_avg_tps as "Daily TPS",
    avg_tps as "Average TPS Over Time"
    from daily_tp,av_tps)
    union all
    (with av_tps as (

    select
    (count(distinct tx_id)/(count(distinct date_trunc('second',block_timestamp)))) as avg_tps
    from osmosis.core.fact_transactions
    where block_timestamp >= '2023-08-15'
    and block_timestamp::date < current_date),

    daily_tp as (
    select
    date(block_timestamp) as date,
    (count(distinct tx_id)/(count(distinct date_trunc('second',block_timestamp)))) as daily_avg_tps
    Run a query to Download Data