Specterproposal creation
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
29
30
31
32
33
34
35
›
⌄
WITH Olash AS (
SELECT block_timestamp, tx_hash,
decoded_log:description AS Topic,
decoded_log:proposalId AS proposalId
FROM ethereum.core.ez_decoded_event_logs
--WHERE tx_hash = '0x0c5eb27954c03bcb440361c8dc52955e7647a6db3ab71f57c62666956df68936'
where event_name = 'ProposalCreated'
AND origin_to_address = '0x34471096285c2b59164e20c03f6977423a450039'
)
SELECT Date_trunc('month', block_timestamp) AS Date,
COUNT(DISTINCT tx_hash) AS no_of_proposals,
SUM(no_of_proposals) OVER (ORDER BY date) AS Cum_proposla
FROM Olash
GROUP BY Date
ORDER BY date Desc
-- ---proposal
-- SELECT block_timestamp, tx_hash, origin_from_address,
-- 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 support = 0
-- AND tx_status = 'SUCCESS'
QueryRunArchived: QueryRun has been archived