# How to only get the highest score of a token graphs multiple sub-queries

**URL:** <https://discuss.elastic.co/t/how-to-only-get-the-highest-score-of-a-token-graphs-multiple-sub-queries/325046>\
**Category:** Elasticsearch\
**Created:** [February 8, 2023, 4:47pm UTC](https://discuss.elastic.co/t/how-to-only-get-the-highest-score-of-a-token-graphs-multiple-sub-queries/325046 "2023-02-08T16:47:30Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nicolas\_Labrot](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nicolas_labrot/32/2177_2.png) [@Nicolas\_Labrot](https://discuss.elastic.co/u/Nicolas_Labrot)\
**Post date:** [February 8, 2023, 4:47pm UTC](https://discuss.elastic.co/t/how-to-only-get-the-highest-score-of-a-token-graphs-multiple-sub-queries/325046/1 "2023-02-08T16:47:30Z")

</div>

Hello,

For example, is indexed "european union" with an hunspell english filter.

The filter generates the following tokens

- token: european / position: 0
- token: union / position: 1
- token: ion / position: 1

If I do a phrase match on "european union", it will then match "european union" and "european ion" , the score will be the double.

Is there the possibility to only get the maximum?

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:** [March 8, 2023, 4:47pm UTC](https://discuss.elastic.co/t/how-to-only-get-the-highest-score-of-a-token-graphs-multiple-sub-queries/325046/2 "2023-03-08T16:47:32Z")

</div>

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