MLDZMNil2
Updated 2022-07-25
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
›
⌄
with tb1 as (select *
from ethereum.core.ez_token_transfers
where to_address ilike '0x397ff1542f962076d0bfe58ea045ffa2d347aca0'
and ORIGIN_FUNCTION_SIGNATURE = '0xf305d719'
and block_number between 14000000 and 15180000
),
tb2 as (select
tx_hash,
BLOCK_NUMBER,
BLOCK_TIMESTAMP,
FROM_ADDRESS as depositor,
sum(AMOUNT) as deposit_USDC,
sum(AMOUNT_USD) as deposit_value_USDC
from tb1
where SYMBOL='USDC'
group by 1,2,3,4),
tb3 as (select
tx_hash,
BLOCK_NUMBER,
BLOCK_TIMESTAMP,
FROM_ADDRESS as depositor,
sum(AMOUNT) as deposit_ETH,
sum(AMOUNT_USD) as deposit_value_ETH
from tb1
where SYMBOL='WETH'
group by 1,2,3,4),
tb4 as (select
HOUR,
price as ETH_price
from ethereum.core.fact_hourly_token_prices
where SYMBOL='WETH')