Query editor
SELECT*,pair_vol / total_vol AS percFROM (SELECTblock_date,SUM(amount_usd) AS total_vol,SUM(CASEWHEN project_contract_address NOT IN (0x8ad599c3a0ff1de082011efddc58f1908eb6e6d8,0xb4e16d0168e52d35cacd2c6185b44281ec28c9dc,0x7bea39867e4169dbe237d55c8242a8f2fcdcc387,0x88e6a0c2ddd26feeb64f039a2c41296fcb3f5640,0xe0554a476a092703abdb3ef35c80e0d76d32939f,0x91644b157163e554a674f83e054ce59533d8a649,0x5bd27b70e058300cc44248a4e7b9cebfc89ed460,0x97dec872013f6b5fb443861090ad931542878126)THEN amount_usdELSE NULLEND) AS other_vol,SUM(CASEWHEN project_contract_address IN (0x8ad599c3a0ff1de082011efddc58f1908eb6e6d8,0xb4e16d0168e52d35cacd2c6185b44281ec28c9dc,0x7bea39867e4169dbe237d55c8242a8f2fcdcc387,0x88e6a0c2ddd26feeb64f039a2c41296fcb3f5640,0xe0554a476a092703abdb3ef35c80e0d76d32939f,0x91644b157163e554a674f83e054ce59533d8a649,0x5bd27b70e058300cc44248a4e7b9cebfc89ed460,0x97dec872013f6b5fb443861090ad931542878126)THEN amount_usdELSE NULLEND) AS pair_volFROM dex.tradesWHEREblockchain = 'ethereum'AND project = 'uniswap'AND block_date >= TIMESTAMP '2023-01-01'GROUP BY 1)/*usdc/usdtCASEWHEN project_contract_address IN (0x3416cf6c708da44db2624d63ea0aaef7113527c6,0x7858e59e0c01ea06df3af3d20ac7b0003275d4bf,0xee4cf3b78a74affa38c6a926282bcd8b5952818d,0xbb256c2f1b677e27118b0345fd2b3894d2e6d487)THEN amount_usdELSE NULLEND) AS pair_vol*/