Sajjadiii1.2Sushi-109
Updated 2022-08-24Copy Reference Fork
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
›
⌄
select 'farmers 'as type ,
count (distinct origin_FROM_ADDRESS) as total_farmers
from ethereum.core.fact_event_logs
where block_timestamp >= CURRENT_DATE() - interval '1 year'
and contract_address = '0xef0881ec094552b2e128cf945ef17a6752b4ec5d' --MasterChefV2
and EVENT_NAME = 'Deposit'
and TX_STATUS = 'SUCCESS'
group by 1
union
select 'amount'as type ,
sum(event_inputs:amount/pow(10,18))as total_farm_amount_Eth
from ethereum.core.fact_event_logs
where block_timestamp >= CURRENT_DATE() - interval '1 year'
and contract_address = '0xef0881ec094552b2e128cf945ef17a6752b4ec5d' --MasterChefV2
and EVENT_NAME = 'Deposit'
and TX_STATUS = 'SUCCESS'
group by 1
Run a query to Download Data