Moefffllllwww10*
Updated 2023-01-11
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 prices as (select date(TIMESTAMP) date ,TOKEN_CONTRACT ID,
avg(PRICE_USD) as price
from
flow.core.fact_prices
where
TIMESTAMP between '2022-12-01' and CURRENT_DATE -1
group by 1,2
)
-- select
-- 'Bridge out' as type ,
-- date_trunc('day', BLOCK_TIMESTAMP)::date AS DAY,
-- monthname(BLOCK_TIMESTAMP) AS Month,
-- -1*sum(AMOUNT*price) AS Volume,
-- -1*avg(AMOUNT*price) AS avg_Volume,
-- -1*count(distinct FLOW_WALLET_ADDRESS) as Bridger,
-- -1*count(distinct TX_ID) as txns
-- from flow.core.ez_bridge_transactions s , prices p
-- where direction ilike '%out%'
-- and block_timestamp::date = date
-- and TOKEN_CONTRACT = ID
-- group by 2,3
-- union all
select
monthname(BLOCK_TIMESTAMP) AS Month,
sum(AMOUNT*price) AS Volume,
avg(AMOUNT*price) AS avg_Volume,
count(distinct FLOW_WALLET_ADDRESS) as Bridger,
count(distinct TX_ID) as txns,
Run a query to Download Data