# Highlight the not correct matching keyword

**URL:** <https://discuss.elastic.co/t/highlight-the-not-correct-matching-keyword/349576>\
**Category:** Elastic Search\
**Tags:** elastic-app-search\
**Created:** [December 18, 2023, 4:05pm UTC](https://discuss.elastic.co/t/highlight-the-not-correct-matching-keyword/349576 "2023-12-18T16:05:49Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ahyh](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ahyh/32/130116_2.png) [@ahyh](https://discuss.elastic.co/u/ahyh)\
**Post date:** [December 18, 2023, 4:05pm UTC](https://discuss.elastic.co/t/highlight-the-not-correct-matching-keyword/349576/1 "2023-12-18T16:05:50Z")

</div>

Hello, I got a problem about highlight query, the highlight result maybe not matching the filter, I am not sure is this a problem with Elasticsearch or not, could you please help confirm?

This is my data in /test:  
{  
"id": 1,  
"desc": "Enable easy troubleshooting, debugging, and profiling of virtual threads with existing JDK tools."  
}

and my search condition is like: ("easy" and "disable") or ("virtual"), I parse this multi keyword with operation to BoolQueryBuilder, and search out the data, but highlight result not only contains "virtual" but also "easy" , but I only want to highlight "virtual" as hit this filter.

Many thanks

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [January 15, 2024, 4:06pm UTC](https://discuss.elastic.co/t/highlight-the-not-correct-matching-keyword/349576/2 "2024-01-15T16:06:14Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
