Commit ea00b16d0df91c2af15c667c37dd220f8dec658e
1 parent
4686cb6c
Full text search for backward compatibility
Showing
1 changed file
with
1 additions
and
1 deletions
... | ... | @@ -451,7 +451,7 @@ public class DefaultEntityQueryRepository implements EntityQueryRepository { |
451 | 451 | List<String> searchPredicates = selectionMapping.stream().map(mapping -> { |
452 | 452 | String paramName = mapping.getValueAlias() + "_lowerSearchText"; |
453 | 453 | ctx.addStringParameter(paramName, lowerSearchText); |
454 | - return String.format("LOWER(%s) LIKE :%s", mapping.getValueAlias(), paramName); | |
454 | + return String.format("LOWER(%s) LIKE concat('%%', :%s, '%%')", mapping.getValueAlias(), paramName); | |
455 | 455 | } |
456 | 456 | ).collect(Collectors.toList()); |
457 | 457 | return String.format(" WHERE %s", String.join(" or ", searchPredicates)); | ... | ... |