Spectervote TREND
Updated 2024-10-26
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
›
⌄
-- forked from thirsty-amaranth @ https://flipsidecrypto.xyz/studio/queries/4fefe610-f36b-4c4d-ad90-762e0df35022
WITH Olash AS (
SELECT block_timestamp, tx_hash, origin_from_address AS voters,
decoded_log:proposalId AS proposalId,
decoded_log:support AS support
FROM ethereum.core.ez_decoded_event_logs
WHERE event_name = 'VoteCast'
--AND tx_hash = '0x1624030d36f2af3316892545c1141c9406ab39440b4914205cfc0ad80adf07d8'
and contract_name = 'Governor OLAS'
AND tx_status = 'SUCCESS'
)
SELECT Date_trunc('month', block_timestamp) AS Date,
COUNT(DISTINCT tx_hash) AS no_of_vote,
SUM(no_of_vote) OVER (ORDER BY date) AS Cum_vote,
COUNT(DISTINCT voters) AS voters
FROM Olash
GROUP BY Date
ORDER BY date Desc
---proposal
QueryRunArchived: QueryRun has been archived