# How to get exact word first next followed matches with word?

**URL:** <https://discuss.elastic.co/t/how-to-get-exact-word-first-next-followed-matches-with-word/105420>\
**Category:** Elasticsearch\
**Created:** [October 26, 2017, 11:46am UTC](https://discuss.elastic.co/t/how-to-get-exact-word-first-next-followed-matches-with-word/105420 "2017-10-26T11:46:14Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![pavani](https://avatars.discourse-cdn.com/v4/letter/p/e9a140/32.png) [@pavani](https://discuss.elastic.co/u/pavani)\
**Post date:** [October 26, 2017, 11:46am UTC](https://discuss.elastic.co/t/how-to-get-exact-word-first-next-followed-matches-with-word/105420/1 "2017-10-26T11:46:14Z")

</div>

hello everyone  
I am very new to Elasticsearch, I need to fetch the data with particular word match  
ex: I have data as

> cricketnplay, cricket23, cricket, criketlegend

when I match the word **cricket**  
result will be like 1st one exact match and next followed matches

- cricket
- cricket23
- cricketlegend
- cricketnplay

how to query to get output like this please help  
Thanks in advance

---

<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:** [November 27, 2017, 9:58am UTC](https://discuss.elastic.co/t/how-to-get-exact-word-first-next-followed-matches-with-word/105420/3 "2017-11-27T09:58:35Z")

</div>

Closed on November 27, 2017, 9:58am UTC

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