0xHaM-dnear here impact - transactions info copy
Updated 2024-10-05
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
›
⌄
-- forked from MoDeFi / near here impact - transactions info @ https://flipsidecrypto.xyz/MoDeFi/q/viPB_uyydqiT/near-here-impact---transactions-info
-- select
-- case
-- when ifnull(tx:actions[0]:Delegate:delegate_action:receiver_id::string, TX_RECEIVER) ilike 'tg'
-- or ifnull(tx:actions[0]:Delegate:delegate_action:receiver_id::string, TX_RECEIVER) ilike '%.hot.tg'
-- or ifnull(tx:actions[0]:Delegate:delegate_action:receiver_id::string, TX_RECEIVER) ilike '%.herewallet.near'
-- then 'Here Wallet' else 'Other' end as "Type",
-- count(*) as "Transactions",
-- count(distinct ifnull(tx:actions[0]:Delegate:delegate_action:sender_id::string, TX_SIGNER)) as "AUs",
-- sum(TRANSACTION_FEE/1e24) as "Fees"
-- from near.core.fact_transactions
-- where TX_SUCCEEDED=true
-- and BLOCK_TIMESTAMP::date>='2023-10-01'
-- group by 1
-- order by 1 desc
with hereW as (
select
BLOCK_TIMESTAMP,
case
when ifnull(tx:actions[0]:Delegate:delegate_action:receiver_id::string, TX_RECEIVER) ilike 'tg'
or ifnull(tx:actions[0]:Delegate:delegate_action:receiver_id::string, TX_RECEIVER) ilike '%.hot.tg'
or ifnull(tx:actions[0]:Delegate:delegate_action:receiver_id::string, TX_RECEIVER) ilike '%.herewallet.near'
then 'Here Wallet' else 'Other' end as type,
TX_HASH,
ifnull(tx:actions[0]:Delegate:delegate_action:sender_id::string, TX_SIGNER) as user,
TRANSACTION_FEE/1e24 as fee
from near.core.fact_transactions
where TX_SUCCEEDED=true
and BLOCK_TIMESTAMP::date>='2023-10-01'
)
-- ,
-- mainTb as (
SELECT
QueryRunArchived: QueryRun has been archived