# Can't get good results

**URL:** <https://discuss.elastic.co/t/cant-get-good-results/119744>\
**Category:** Elasticsearch\
**Created:** [February 14, 2018, 7:40am UTC](https://discuss.elastic.co/t/cant-get-good-results/119744 "2018-02-14T07:40:39Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kandelakil](https://avatars.discourse-cdn.com/v4/letter/k/977dab/32.png) [@Kandelakil](https://discuss.elastic.co/u/Kandelakil)\
**Post date:** [February 14, 2018, 7:40am UTC](https://discuss.elastic.co/t/cant-get-good-results/119744/1 "2018-02-14T07:40:39Z")

</div>

Please help us to solve the following issue:

The problem is.....  
We do not have a specific queue. Default query is \_search?q={$q}  
This search query is not getting the result for me.  
When we tried different queues, we could not get a good/exact result.

For example: thes query " ?q=title: iphone 7"

We get the results:

cases iphone 6 64gb  
Hoco UltraSlim TPU Case iPhone X  
HOCO Light Series TPU for iPhone X - Transparent Black  
Monsterskin Super Impact Proof for iPhone X

We want to get the results where you will be able to find the results.

iphone 7 mobile phones.  
iphone 7 32gb mobile phones.  
iphone 7 128gb mobile phones.

 ![1-1](https://us1.discourse-cdn.com/elastic/original/3X/e/a/eaa2d0290a245c480183885760ba5b545ddecd2f.png) ![2](https://us1.discourse-cdn.com/elastic/original/3X/d/2/d246a1c39f4cf22fb49ea672f690fa04bafc699f.png) ![1](https://us1.discourse-cdn.com/elastic/original/3X/e/7/e7e93c4c946e11150a2b0c889740d5c7767c5104.png)

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [February 14, 2018, 7:55am UTC](https://discuss.elastic.co/t/cant-get-good-results/119744/2 "2018-02-14T07:55:47Z")

</div>

you can try `match_phrase` query? [https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-match-query-phrase.html](https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-match-query-phrase.html)

---

<div class="post-metadata">

**Author:** ![Kandelakil](https://avatars.discourse-cdn.com/v4/letter/k/977dab/32.png) [@Kandelakil](https://discuss.elastic.co/u/Kandelakil)\
**Post date:** [February 14, 2018, 8:38am UTC](https://discuss.elastic.co/t/cant-get-good-results/119744/3 "2018-02-14T08:38:37Z")

</div>

If the keyword does not match by 100%, then the result is 0

 ![res_1](https://us1.discourse-cdn.com/elastic/original/3X/7/6/766d9a80c003e1848275c8b4cd81ca8ff4795e87.png) ![res_3](https://us1.discourse-cdn.com/elastic/original/3X/7/3/73d7a0be0e169f37d8d657c9f38d0640a115b53c.png) ![res_2](https://us1.discourse-cdn.com/elastic/original/3X/1/d/1d2b1750cf69936d0609b12b47c4b44cf8ef9d79.png)

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [February 14, 2018, 9:47am UTC](https://discuss.elastic.co/t/cant-get-good-results/119744/4 "2018-02-14T09:47:02Z")

</div>

Please don't post images of text as they are hardly readable and not searchable.

Instead paste the text and format it with `</>` icon. Check the preview window.

> If the keyword does not match by 100%, then the result is 0

Yes. This is not what you asked for.

Anyway, here is a script that might help you to build a nice combination of different type of queries:

> <https://gist.github.com/dadoonet/5179ee72ecbf08f12f53d4bda1b76bab>

---

<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 14, 2018, 9:47am UTC](https://discuss.elastic.co/t/cant-get-good-results/119744/5 "2018-03-14T09:47:05Z")

</div>

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