Skip to content

Commit

Permalink
Fix to avoid summing duplicated transactions
Browse files Browse the repository at this point in the history
  • Loading branch information
ushitora-anqou committed Sep 2, 2023
1 parent 8df82f7 commit 1098db8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/web_server.ml
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ cash_account_ids AS (
WHERE t.name = '#cash'
),
target_postings AS (
SELECT p2.*
SELECT DISTINCT p2.*
FROM postings p1, postings p2
WHERE p1.transaction_id = p2.transaction_id
AND p1.account_id IN ( SELECT * FROM cash_account_ids )
Expand Down Expand Up @@ -121,7 +121,7 @@ cash_account_ids AS (
WHERE t.name = '#cash'
),
target_postings AS (
SELECT p2.*
SELECT DISTINCT p2.*
FROM postings p1, postings p2
WHERE p1.transaction_id = p2.transaction_id
AND p1.account_id IN ( SELECT * FROM cash_account_ids )
Expand Down

0 comments on commit 1098db8

Please sign in to comment.