binhachonUntitled Query
Updated 2022-01-21
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 ENS_raw_transactions as (
select
distinct
date_trunc('day', block_timestamp) as block_timestamp,
tx_id,
from_address as address,
-amount as amount
from ethereum.udm_events
where contract_address = '0xc18360217d8f7ab5e7c516566761ea12ce7f9d72'
and amount is not null
union all
select
distinct
date_trunc('day', block_timestamp) as block_timestamp,
tx_id,
to_address as address,
amount
from ethereum.udm_events
where contract_address = '0xc18360217d8f7ab5e7c516566761ea12ce7f9d72'
and amount is not null
),
ENS_daily_transactions as (
select
block_timestamp,
case
when address = '0xc18360217d8f7ab5e7c516566761ea12ce7f9d72' then 'Airdrop address'
when address = '0xd7a029db2585553978190db5e85ec724aa4df23f' then 'Locked address'
when address = '0xfe89cc7abb2c4183683ab71653c4cdc9b02d44b7' then 'DAO treasury'
else 'Circulating supply' end
as adjusted_address,
sum(amount) as amount
from ENS_raw_transactions
where address != '0x0000000000000000000000000000000000000000'
group by block_timestamp, adjusted_address
)
-- day_list as (
Run a query to Download Data