diff --git a/dao/src/main/java/life/catalogue/es/EsNameUsage.java b/dao/src/main/java/life/catalogue/es/EsNameUsage.java index 4755a90fa2..508d286cab 100644 --- a/dao/src/main/java/life/catalogue/es/EsNameUsage.java +++ b/dao/src/main/java/life/catalogue/es/EsNameUsage.java @@ -50,7 +50,7 @@ public class EsNameUsage { private TaxonomicStatus status; private Set issues; private Set environments; - @Analyzers(STANDARD_ASCII) + @Analyzers(KEYWORD) private List classificationIds; private Boolean extinct; diff --git a/dao/src/test/java/life/catalogue/es/nu/search/NameUsageSearchParameterTest.java b/dao/src/test/java/life/catalogue/es/nu/search/NameUsageSearchParameterTest.java index 89e86a3342..570562c9dc 100644 --- a/dao/src/test/java/life/catalogue/es/nu/search/NameUsageSearchParameterTest.java +++ b/dao/src/test/java/life/catalogue/es/nu/search/NameUsageSearchParameterTest.java @@ -74,6 +74,11 @@ public void testTaxonId1() { List expected = Arrays.asList(nuw1, nuw2, nuw3); assertEquals(expected, search(query).getResult()); + query = new NameUsageSearchRequest(); + query.addFilter(TAXON_ID, "4"); + expected = Arrays.asList(nuw2, nuw3, nuw4); + assertEquals(expected, search(query).getResult()); + countdown(TAXON_ID); }