Query editor
select ft.blockchain,ft.epoch,ft.block_time,ft.tx_hash,ft.metamask_contract,ft.token_address,ft.token,ft.price,ft.amount_raw,ft.amount,case when ft.price > 0 then ft.amount_usdwhen t.amount_usd > 0 then t.amount_usd / cast(t.token_bought_amount_raw as uint256) * ft.amount_rawwhen t2.amount_usd > 0 then t2.amount_usd / cast(t2.token_sold_amount_raw as uint256) * ft.amount_rawend as amount_usd -- Fetch from dex or calculate with token pricefrom dune.bennyfeng.result_paraswap_metamasks_transfers ftleft join dex.trades t on ft.tx_hash = t.tx_hashand ft.blockchain = t.blockchainand ft.token_address = t.token_bought_addressand t.amount_usd > 0left join dex.trades t2 on ft.tx_hash = t2.tx_hashand ft.blockchain = t2.blockchainand ft.token_address = t2.token_sold_addressand t2.amount_usd > 0