mariyaAstroport amount and address count
Updated 2022-03-11
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
›
⌄
with lst_wallets_90 as (
select tx_from[0] as wallet
,min(block_timestamp)::date as min_date
from terra.transactions
group by 1
having min_date>=CURRENT_DATE-90
)
,lst_tx_id as (
select DISTINCT tx_id from terra.transactions
where tx_from[0] in(select wallet from lst_wallets_90)
)
select
date(block_timestamp) as day
,count(tx_id) tx_count
,count( msg_value:sender) as address_count
,sum(msg_value:execute_msg:send:amount/1e6) as amount
from terra.msgs
where tx_status = 'SUCCEEDED'
and msg_value:contract::string = 'terra1nuy34nwnsh53ygpc4xprlj263cztw7vc99leh2' --Astroport
and msg_value:execute_msg:send:amount is not null
and msg_value:execute_msg:send:amount/1e6>0
and tx_id in(select tx_id from lst_tx_id)
group by 1
order by 1
Run a query to Download Data