kiacryptotps
Updated 2022-12-09Copy Reference Fork
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
›
⌄
with info as (
select
date_trunc('hour', block_timestamp) as hour,
count(distinct tx_id) as tx_count,
tx_count/3600 as tps
from terra.core.fact_transactions
group by 1
),
final_tps as (
SELECT
date_trunc('week', hour) as weekly,
avg(tps) as avg_tps
from info
group by 1
order by 1 asc
),
avg_info as (
select avg(avg_tps) as all_tps
from final_tps
)
select *
from final_tps, avg_info
Run a query to Download Data