mattkstewProposal Descriptions
Updated 2023-02-01Copy Reference Fork
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 tab1 as (
select
tx_hash
from near.core.fact_transactions
where TX_RECEIVER like 'marketing.sputnik-dao.near'
)
, tab2 as (
select
block_timestamp as date,
Parse_JSON(args) as Args
from near.core.fact_actions_events_function_call
where tx_hash in (select * from tab1)
and method_name like 'add_proposal'
)
, tab3 as (
select
date_trunc('day', date) as date,
args:proposal:description as info,
regexp_substr(Args, '"amount":"([^"]+)"') as amount,
regexp_substr(Args, '"receiver_id":"([^"]+)"') as receiver_id
from tab2
)
select
date_trunc('day', date) as Date,
info as Descriptions
from tab3
order by 1 desc
Run a query to Download Data