When I use Infinispan with Hibernate, I need to use Analyzer to find results which includes the key word.
But when I search the keyword SNO_NO_D6-11100
with query like:
QueryBuilder queryBuilder = CSECore.searchManager
.buildQueryBuilderForClass(Hierarchy.class).get();
Query query = queryBuilder
.keyword().onField("path").matching("SNO_NO_D6-11100").createQuery();
It seperatesSNO_NO_D6-11100
to SNO_NO_D6
and 11100
then find them respectively and merge 2 results together. There will be some results incorrect.
If I ignore the analyzer, it will just find the exact match which is also incorrect. Is there a solution that Analyzer can ignore the "-" ??