Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ public Page<LoanAccountData> retrieveAll(final SearchParameters searchParameters
// to support senario where loan has group_id only OR client_id will
// probably require a UNION query
// but that at present is an edge case
sqlBuilder.append(" join m_office o on o.id = c.office_id");
sqlBuilder.append(" join m_office o on (o.id = c.office_id or o.id = g.office_id) ");
sqlBuilder.append(" left join m_office transferToOffice on transferToOffice.id = c.transfer_to_office_id ");
sqlBuilder.append(" where ( o.hierarchy like ? or transferToOffice.hierarchy like ?)");

Expand Down