select
block_timestamp::date as days,
blockchain,
collateral_symbol,
count(distinct tx_hash) as number_of_borrowing,
sum(amount_usd) as amount_for_borrowing,
count(distinct origin_from_address) as number_of_wallet
from crosschain.ez_borrowing
where collateral_symbol in ('USDC', 'USDT', 'DAI', 'TUSD', 'sUSD', 'UST', 'USDN')
and lending_pool ilike 'km%'
and action = 'Borrow'
group by days, blockchain, collateral_symbol
order by days