Query editor
with cex as (select * from cex.addresseswhere cex_name in ('BtcTurk', 'Paribu')),tx as(select *from ethereum.transactionswhere "from" in (select address from cex) and block_time >= NOW()-INTERVAL '1' yearunion allselect *from ethereum.transactionswhere "to" in (select address from cex) and block_time >= NOW()-INTERVAL '1' year),labels as (selecttx.*,coalesce(c1.cex_name,c2.cex_name,'null') as namefrom txleft join cex c1 on c1.address = tx."from"left join cex c2 on c2.address = tx."to")selectdate_trunc('week',block_time) as dt,name,count(*) as total_txsfrom labelsgroup by 1, 2