Skip to content

Commit

Permalink
chore: update pool snapshots query
Browse files Browse the repository at this point in the history
  • Loading branch information
martines3000 committed Jan 6, 2025
1 parent 969f0a6 commit 2ceba1c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion apps/indexer-sentio/queries/pool_snapshots.sql
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,9 @@ SELECT timestamp,
borrowIndex AS borrow_index,
borrowApr AS borrow_apr,
totalFeesUsd AS total_fees_usd,
userFeesUsd AS user_fees_usd,
(
borrowedAmountUsd * borrowApr - suppliedAmountUsd * supplyApr
) / 100 / 365 / 24 as user_fees_usd,
protocolFeesUsd AS protocol_fees_usd
FROM `BasePoolSnapshot_raw`
WHERE timestamp > timestamp('{{timestamp}}')

0 comments on commit 2ceba1c

Please sign in to comment.