Nige7777Untitled Query
Updated 2022-02-23
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
›
⌄
with cte_1 as (
select
--count(DISTINCT tx_id) over ( partition by DATE_TRUNC('Second',block_timestamp) order by block_timestamp ) as TRANS,
count(DISTINCT tx_id) as trans,
DATE_TRUNC('Second',block_timestamp) as S
from
solana.transactions
where succeeded = 'TRUE' and
block_timestamp::date >= '2022-2-01' AND block_timestamp::date <= '2022-2-14'
-- and fee > 0
group by 2
limit 100
)
select
--sum(trans) Total_TPS,
avg(trans ) AVERAGE_TPS,
min(Trans ) LOWEST_TPS,
max(TRANS) HIGHEST_TPS,
DATE_TRUNC('hour',s) as Hour,
DATE_TRUNC('DAY',s) as day
from cte_1
group by
hour,
day
Run a query to Download Data