datavortexStake stone
Updated 2025-01-09
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
›
⌄
WITH stake_stone AS (
SELECT
t.owner AS address,
t.amount,
t.tx_hash
FROM $query('ee8999b8-1f68-4ccf-9784-8d2a21e3b7ff') t
),
average_weth_price AS (
SELECT
AVG(price) AS avg_price_usd
FROM ethereum.price.ez_prices_hourly
WHERE token_address = '0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2'
AND hour >= '2024-12-01'
AND hour <= '2024-12-31'
)
SELECT
'stake stone' AS project,
COUNT(DISTINCT address) AS total_users,
SUM(CAST(amount AS DECIMAL(38, 0)) / CAST(1e18 AS DECIMAL(38, 18)) * avg_price_usd) AS total_amount_usd,
COUNT(DISTINCT tx_hash) AS total_transactions,
FROM stake_stone, average_weth_price;
QueryRunArchived: QueryRun has been archived