# Is there a query that makes the word searched closer to the beginning of the text get more points?

**URL:** <https://discuss.elastic.co/t/is-there-a-query-that-makes-the-word-searched-closer-to-the-beginning-of-the-text-get-more-points/294483>\
**Category:** Elasticsearch\
**Created:** [January 15, 2022, 3:12pm UTC](https://discuss.elastic.co/t/is-there-a-query-that-makes-the-word-searched-closer-to-the-beginning-of-the-text-get-more-points/294483 "2022-01-15T15:12:34Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Amir\_Faramarzi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/amir_faramarzi/32/92919_2.png) [@Amir\_Faramarzi](https://discuss.elastic.co/u/Amir_Faramarzi)\
**Post date:** [January 15, 2022, 3:12pm UTC](https://discuss.elastic.co/t/is-there-a-query-that-makes-the-word-searched-closer-to-the-beginning-of-the-text-get-more-points/294483/1 "2022-01-15T15:12:34Z")

</div>

hello

Is there a query that makes the word searched closer to the beginning of the text get more points ??

For example, if we have two texts as follows

Samsung mobile phone cover  
TypeC charger with fast charging capability for Samsung mobile phone

And the user will search for the word "Samsung mobile phone"  
First comes the "Samsung mobile phone cover" and then the "typeC charger with fast charging capability for Samsung mobile phone"

If so, what is the query and what should the mapping field look like?

---

<div class="post-metadata">

**Author:** ![Amir\_Faramarzi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/amir_faramarzi/32/92919_2.png) [@Amir\_Faramarzi](https://discuss.elastic.co/u/Amir_Faramarzi)\
**Post date:** [January 16, 2022, 12:27pm UTC](https://discuss.elastic.co/t/is-there-a-query-that-makes-the-word-searched-closer-to-the-beginning-of-the-text-get-more-points/294483/2 "2022-01-16T12:27:06Z")

</div>

@Mark_Harwood @DavidTurner

---

<div class="post-metadata">

**Author:** ![Amir\_Faramarzi](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/amir_faramarzi/32/92919_2.png) [@Amir\_Faramarzi](https://discuss.elastic.co/u/Amir_Faramarzi)\
**Post date:** [January 16, 2022, 12:41pm UTC](https://discuss.elastic.co/t/is-there-a-query-that-makes-the-word-searched-closer-to-the-beginning-of-the-text-get-more-points/294483/3 "2022-01-16T12:41:04Z")

</div>

@Tomo_M Do not have an opinion?

---

<div class="post-metadata">

**Author:** ![DavidTurner](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/davidturner/32/22453_2.png) [@DavidTurner](https://discuss.elastic.co/u/DavidTurner)\
**Post date:** [January 16, 2022, 12:44pm UTC](https://discuss.elastic.co/t/is-there-a-query-that-makes-the-word-searched-closer-to-the-beginning-of-the-text-get-more-points/294483/4 "2022-01-16T12:44:44Z")

</div>

It's impolite to `@mention` random people that aren't involved in your conversation. Please don't do this.

---

<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:** [February 13, 2022, 12:45pm UTC](https://discuss.elastic.co/t/is-there-a-query-that-makes-the-word-searched-closer-to-the-beginning-of-the-text-get-more-points/294483/5 "2022-02-13T12:45:37Z")

</div>

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