Add buys query table from exchange_to_wallet events
Denormalized read table with id, event_id, occurred_at, wallet, sats, fee_sats, and amount_eur. Projected on event creation and rebuildable via POST /api/buys/rebuild. Fiat amounts converted to EUR using Frankfurter rates. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
ALTER TABLE buys ADD COLUMN sats BIGINT NOT NULL DEFAULT 0;
|
||||
--;;
|
||||
ALTER TABLE buys ADD COLUMN fee_sats BIGINT;
|
||||
Reference in New Issue
Block a user