[
https://issues.apache.org/jira/browse/FINERACT-1957?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Kigenyi Wilfred updated FINERACT-1957:
--------------------------------------
Description:
Consider a savings a account that has automatic withdraw charges of 1%. When a
withdraw transaction of happens it will automatically cause a withdrawal charge
transaction to happen at the same time. Both these transactions will be listed
on the account but running balances on the two transactions are some times
interchanged.
Attached is a screenshot of case.
In the ScreenShot1, the latest transaction (with ID = 71890) is not assigned
the correct account balance and that balance is instead assigned to the second
last transaction (id = 718889)
In the ScreenShot2, the latest transaction is assigned the correct account
balance which is correct. However this behavior is unpredictable in other words
one one cannot reliably tell the account balance by looking at the running
balance of the latest transaction. There should be consistence, that is, the
latest transaction on account should reliably be assigned the current account
balance.
This inconsistency can lead errors when when determining the opening and
closing balance when making a report about an account considering an opening
date and a closing date.
was:When using automatic withdrawal charges on a savings account, it
sometimes happens that the withdrawal transaction and the corresponding
withdrawal charge transaction happen at "The same time". Sometimes the
withdrawal transaction happens before the charge transaction and sometimes it
is the other way round, so one cannot predict if the transaction id for the
charge transaction will be greater or less that of the actual withdrawal
transaction. Since the SavingsAccountTransactionComparator compares
created_date (these can be the same) and id (there is no assurance as to which
one will come first), the comparison become unpredictable for this particular
case and the logic sometimes ends up interchanging running balances on the
transactions. So when a list of transactions is pulled it may show the
interchanged running balances for withdrawal charge transaction and the
withdrawal transaction.
> Unpredicatable assignment of running balances to withdrawal transactions that
> are happening on the same involving withdrawal charges
> ------------------------------------------------------------------------------------------------------------------------------------
>
> Key: FINERACT-1957
> URL: https://issues.apache.org/jira/browse/FINERACT-1957
> Project: Apache Fineract
> Issue Type: Improvement
> Components: Savings
> Affects Versions: 1.7.3, 1.7.2, 1.8.3, 1.8.2
> Reporter: Kigenyi Wilfred
> Assignee: Francis Guchie
> Priority: Major
> Fix For: 1.10.0
>
>
> Consider a savings a account that has automatic withdraw charges of 1%. When
> a withdraw transaction of happens it will automatically cause a withdrawal
> charge transaction to happen at the same time. Both these transactions will
> be listed on the account but running balances on the two transactions are
> some times interchanged.
> Attached is a screenshot of case.
> In the ScreenShot1, the latest transaction (with ID = 71890) is not assigned
> the correct account balance and that balance is instead assigned to the
> second last transaction (id = 718889)
> In the ScreenShot2, the latest transaction is assigned the correct account
> balance which is correct. However this behavior is unpredictable in other
> words one one cannot reliably tell the account balance by looking at the
> running balance of the latest transaction. There should be consistence, that
> is, the latest transaction on account should reliably be assigned the current
> account balance.
> This inconsistency can lead errors when when determining the opening and
> closing balance when making a report about an account considering an opening
> date and a closing date.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)