cindiePrice and circulating
Updated 2022-06-08Copy Reference Fork
99
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
›
⌄
with table_1 as (select balance_date::date per_day,
sum(balance) as supply
from flipside_prod_db.ethereum.erc20_balances
where lower (contract_address) = lower ('0x7D1AfA7B718fb893dB30A3aBc0Cfc608AaCfeBB0')
and user_address not in (select address from ethereum.core.dim_labels WHERE
address ilike '0x50d669f43b484166680ecc3670e4766cdb0945ce' or address ilike '0xcd6507d87f605f5e95c12f7c4b1fc3279dc944ab'
or address ilike '0x401f6c983ea34274ec46f84d70b31c151321188b')
group by 1),
table_2 as (select date_trunc('day', hour) per_day,
avg(price) as price
from ethereum.core.fact_hourly_token_prices
where lower (token_address) = lower ('0x7D1AfA7B718fb893dB30A3aBc0Cfc608AaCfeBB0')
group by 1)
select table_1.per_day, supply, price
from table_1, table_2 where table_1.per_day = table_2.per_day
Run a query to Download Data