Query editor
WITHbase AS (SELECT DISTINCTcontract,"from","to",order_source,price,token_id,tx_hash,currency_address,currency_symbol,usd_price,tx_timestamp_dtFROMreservoir.salesWHEREtx_hash IN (SELECTcall_tx_hashFROMuniswap_ethereum.UniversalRouter_call_execute)AND "from" <> 0xef1c6e67703c7bd7107eed8303fbe6ec2554bf6bAND "to" <> 0xef1c6e67703c7bd7107eed8303fbe6ec2554bf6b)SELECTDATE_TRUNC('day', CAST(tx_timestamp_dt AS TIMESTAMP)) AS day,COUNT(DISTINCT tx_hash) AS txs,COUNT(DISTINCT "from") AS seller,COUNT(DISTINCT "to") AS buyer,SUM(usd_price / CAST(1e6 AS DOUBLE)) AS usd_volumeFROMbaseGROUP BY1