kiacryptodaily tps - layer 2
    Updated 2023-03-10
    with arbi_tps as (
    select
    date_trunc('second', block_timestamp) as sec,
    count(distinct tx_hash) as tx_count
    from arbitrum.core.fact_transactions
    where
    block_timestamp::date >= '2023-01-01' and
    status = 'SUCCESS'
    group by 1
    ),
    opti_tps as (
    select
    date_trunc('second', block_timestamp) as sec,
    count(distinct tx_hash) as tx_count
    from optimism.core.fact_transactions
    where
    block_timestamp::date >= '2023-01-01' and
    status = 'SUCCESS'
    group by 1
    ),
    poly_tps as (
    select
    date_trunc('second', block_timestamp) as sec,
    count(distinct tx_hash) as tx_count
    from polygon.core.fact_transactions
    where
    block_timestamp::date >= '2023-01-01' and
    status = 'SUCCESS'
    group by 1
    )
    select
    date_trunc('day', sec) as date,
    avg(tx_count) as avg_tps,
    avg(avg_tps) over (order by date, date rows between 6 preceding and current row) as ma7_avg_tps,
    'Arbitrum' as blockchain
    Run a query to Download Data