+ "left join m_loan loanAccount on loanAccount.id = aa.loan_account_id " + "where aa.linked_savings_account_id = ?";
final List<Integer> statusList = this.jdbcTemplate.queryForList(sql, Integer.class, savingsId);
for (final Integer status : statusList) {
if(status !=null){
final LoanStatus loanStatus = LoanStatus.fromInt(status);
if (loanStatus.isActiveOrAwaitingApprovalOrDisbursal() || loanStatus.isUnderTransfer()) { return true; }
}
}
final String savsql = "select savingAccount.status_enum as status from m_portfolio_account_associations aa "
+ "left join m_savings_account savingAccount on savingAccount.id = aa.savings_account_id "