Query editor
WITHdex_trades AS (SELECTtoken_sold_address AS contract_address,amount_usd / CAST(token_sold_amount AS DOUBLE) AS price,block_timeFROMdex.tradesWHEREblockchain = 'ethereum'AND amount_usd > 0--AND category = 'DEX'AND token_sold_amount > 0AND token_sold_address = 0xa19f5264f7d7be11c451c093d8f92592820bea86UNION ALLSELECTtoken_bought_address AS contract_address,amount_usd / CAST(token_bought_amount_raw AS DOUBLE) AS price,block_timeFROMdex.tradesWHEREblockchain = 'ethereum'AND amount_usd > 0--AND project = 'DEX'AND CAST(token_bought_amount_raw AS DOUBLE) > 0AND token_bought_address = 0xa19f5264f7d7be11c451c093d8f92592820bea86)SELECTblock_time,priceFROMdex_tradeswhere block_time is not null-- need to correct this and date_trunc('day', block_time) > '2023-06-16'ORDER BYblock_time DESCLIMIT360