From bbd189991168a2f7ea93142fcea94c7a23b4457f Mon Sep 17 00:00:00 2001 From: PoloX2021 <115744849+PoloX2021@users.noreply.github.com> Date: Tue, 21 Jan 2025 17:27:06 +0000 Subject: [PATCH] Change prices from minute to day to avoid issues in the db (#122) --- cowamm/tvl_by_tx_4059700.sql | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cowamm/tvl_by_tx_4059700.sql b/cowamm/tvl_by_tx_4059700.sql index 6cf9d12..6262c70 100644 --- a/cowamm/tvl_by_tx_4059700.sql +++ b/cowamm/tvl_by_tx_4059700.sql @@ -54,9 +54,9 @@ tvl as ( price, balance * price / POW(10, decimals) as tvl from balances_by_tx as b - inner join prices.minute as p + inner join prices.day as p on - p.timestamp = DATE_TRUNC('minute', evt_block_time) + p.timestamp = DATE_TRUNC('day', evt_block_time) and b.token = p.contract_address )