datavortexDaily Sar=takes
Updated 2024-11-30
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 daily_stakes AS (
SELECT
DATE_TRUNC('DAY', block_timestamp) AS transaction_date,
SUM(amount) AS total_staked_amount,
COUNT(DISTINCT delegator) AS total_delegators,
COUNT(DISTINCT tx_id) AS distinct_transactions
FROM
flow.gov.ez_staking_actions
WHERE
action IN ('TokensStaked', 'DelegatorTokensCommitted', 'TokensCommitted')
AND block_timestamp >= '2024-11-20'
AND block_timestamp < '2024-11-27'
GROUP BY
transaction_date
)
SELECT
transaction_date,
total_staked_amount,
total_delegators,
distinct_transactions
FROM
daily_stakes
ORDER BY
transaction_date;
*/
WITH epoch_boundaries AS (
SELECT
DATE '2024-11-06' AS epoch_start,
DATE '2024-11-13' AS epoch_end
UNION
ALL
SELECT
DATE '2024-11-13',
DATE '2024-11-20'
UNION
QueryRunArchived: QueryRun has been archived