# How match indexof in query?

**URL:** <https://discuss.elastic.co/t/how-match-indexof-in-query/315615>\
**Category:** Kibana\
**Created:** [October 1, 2022, 12:06pm UTC](https://discuss.elastic.co/t/how-match-indexof-in-query/315615 "2022-10-01T12:06:29Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nikolas1306](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nikolas1306/32/111507_2.png) [@Nikolas1306](https://discuss.elastic.co/u/Nikolas1306)\
**Post date:** [October 1, 2022, 12:06pm UTC](https://discuss.elastic.co/t/how-match-indexof-in-query/315615/1 "2022-10-01T12:06:29Z")

</div>

i've used this

```auto
GET /myindex/_search
{
 "query": {
     "match_phrase_prefix": {
       "message": "my text*"
     }
  }
}

```

but not have results i' ve always

```auto
#! Elasticsearch built-in security features are not enabled. Without authentication, your cluster could be accessible to anyone. See https://www.elastic.co/guide/en/elasticsearch/reference/7.16/security-minimal-setup.html to enable security.
{
  "took" : 0,
  "timed_out" : false,
  "_shards" : {
    "total" : 1,
    "successful" : 1,
    "skipped" : 0,
    "failed" : 0
  },
  "hits" : {
    "total" : {
      "value" : 0,
      "relation" : "eq"
    },
    "max_score" : null,
    "hits" : []
  }
}

```

---

<div class="post-metadata">

**Author:** ![RabBit\_BR](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rabbit_br/32/82261_2.png) [@RabBit\_BR](https://discuss.elastic.co/u/RabBit_BR)\
**Post date:** [October 2, 2022, 12:20pm UTC](https://discuss.elastic.co/t/how-match-indexof-in-query/315615/2 "2022-10-02T12:20:30Z")

</div>

Hi @Nikolas1306

Which document do you want to get in the results?

---

<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:** [October 30, 2022, 12:20pm UTC](https://discuss.elastic.co/t/how-match-indexof-in-query/315615/3 "2022-10-30T12:20:57Z")

</div>

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