rackhaelCosmos IBC Transactions
    Updated 2023-08-20
    select date_trunc('day', block_timestamp) as date,
    currency as tokens,
    sum(amount) as atom_vol,
    transfer_type,
    count(tx_id) as transfered_tokens,
    count(distinct sender) as unique_users,
    case when transfer_type = 'IBC_TRANSFER_IN' then 'IBC_in'
    when transfer_type = 'IBC_TRANSFER_OUT' then 'IBC_out'
    else null end as transfers
    from cosmos.core.fact_transfers
    --90 days
    where date >= current_date - 90
    and tx_succeeded = 'true'
    group by date, transfer_type, currency
    order by date, currency desc
    Run a query to Download Data