MahrooUntitled Query
Updated 2022-11-15Copy Reference Fork
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
›
⌄
with claimerst as (
select block_timestamp as claimdate,
event_inputs:recipient as Claimer,
event_inputs:amount/1e18 as Claimed_Volume
from optimism.core.fact_event_logs
where origin_to_address = '0xfedfaf1a10335448b7fa0268f56d2b44dbd357de'
and origin_function_signature = '0x2e7ba6ef'
and event_name = 'Claimed')
select event_name,
count (distinct tx_hash) as TX_Count,
count (distinct origin_from_address) as Users_Count
from optimism.core.fact_event_logs t1 join claimerst t2 on t1.origin_from_address = t2.claimer
full outer join optimism.core.dim_labels t3 on t1.origin_to_address = t3.address
where contract_address = '0x4200000000000000000000000000000000000042'
--and origin_from_address = event_inputs:from
and t1.block_timestamp > t2.claimdate
and event_name is not null
group by 1
order by 2 DESC
Run a query to Download Data