elovianootps
Updated 2024-12-04
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
31
32
33
34
35
36
›
⌄
-- with tps as (
-- select avg(tps) as avg_tps
-- from (
select
date_trunc('day', block_timestamp ) as day
, count(tx_id)/(24*60*60) as tps
from eclipse.core.fact_transactions
where block_timestamp >= DATEADD(DAY, -29, CURRENT_DATE())
group by 1
order by 1
-- )
-- )
-- , avg_daily_txs as (
-- select
-- count(tx_id)/count(distinct date_trunc('day', block_timestamp)) as avg_daily_txs
-- from eclipse.core.fact_transactions
-- where block_timestamp >= DATEADD(DAY, -29, CURRENT_DATE())
-- )
-- , avg_fees as (
-- select
-- avg(fee /1e9) as avg_fee_eth
-- , avg(fee /1e9 * p.price) as avg_fee_usd
-- from eclipse.core.fact_transactions t
-- left join ethereum.price.ez_prices_hourly p
-- on p.hour = date_trunc ('hour', block_timestamp)
-- and p.blockchain = 'ethereum' and p.symbol = 'ETH'
-- where block_timestamp >= DATEADD(DAY, -30, CURRENT_DATE())
-- -- group by 1
-- -- order by 1
-- )
-- select
QueryRunArchived: QueryRun has been archived