c2ctrader01-Unique Users staking Algo to mint gAlgo3
Updated 2022-04-22
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
›
⌄
with Recive_gALGO3 as(
select *,tx_message:txn:aamt/pow(10,6) amount_gALGO3 from algorand.transactions
WHERE sender='4STYTA6TLA2YIPVDX6CAGFD3I6FOAUFXEXVY4C6SAFF4GU557OENP5JBJM' and asset_id='694432641' and inner_tx=TRUE and tx_type_name='asset transfer'
AND block_timestamp BETWEEN '2022-03-31 12:00:00.000' and '2022-04-14 6:00:00.000'
--11
),
payment_ALGO AS(
SELECT *,tx_message:txn:amt/(1e6) amount_algo FROM algorand.transactions
where asset_id=0 and tx_type_name='payment' AND block_timestamp BETWEEN '2022-03-31 12:00:00.000' and '2022-04-14 6:00:00.000'
--11
),
algo_galgo3 as (
select r.tx_group_id,p.block_timestamp timestamp, p.block_id block_id,p.tx_id payment_algo_tx_id,p.sender user_wallet_address,
r.tx_id sending_galgo3_tx_id, r.sender sender_galgo3_address,r.amount_galgo3
from Recive_gALGO3 r join payment_ALGO p on r.tx_group_id=p.tx_group_id
order by r.block_timestamp
)
select count(*) total_transactions, count(DISTINCT(user_wallet_address)) total_unique_users,round(sum(amount_galgo3),0) total_galgo3 from algo_galgo3
Run a query to Download Data