You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@fineract.apache.org by "Emmanuel Nnaa (JIRA)" <ji...@apache.org> on 2016/02/24 10:44:18 UTC

[jira] [Created] (FINERACT-44) Cannot delete an inactive charge

Emmanuel Nnaa created FINERACT-44:
-------------------------------------

             Summary: Cannot delete an inactive charge
                 Key: FINERACT-44
                 URL: https://issues.apache.org/jira/browse/FINERACT-44
             Project: Apache Fineract
          Issue Type: Bug
            Reporter: Emmanuel Nnaa
            Assignee: Markus Geiss
            Priority: Minor


The SQL statement in the methods (isAnyLoansAssociateWithThisCharge and isAnySavingsAssociateWithThisCharge) that check if a charge is attached to a product (loan or savings) does not include the "and is_active = 1" criterion.

*Solution*
{code}
final String sql = "select if((exists (select 1 from m_loan_charge lc where lc.charge_id = ? and lc.is_active = 1)) = 1, 'true', 'false')";

final String sql = "select if((exists (select 1 from m_savings_account_charge sc where sc.charge_id = ? and sc.is_active = 1)) = 1, 'true', 'false')";
{code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)