# Query Prefix Numbers and Dates

**URL:** <https://discuss.elastic.co/t/query-prefix-numbers-and-dates/288044>\
**Category:** Elasticsearch\
**Created:** [October 29, 2021, 10:59pm UTC](https://discuss.elastic.co/t/query-prefix-numbers-and-dates/288044 "2021-10-29T22:59:00Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![elipongr](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/elipongr/32/96551_2.png) [@elipongr](https://discuss.elastic.co/u/elipongr)\
**Post date:** [October 29, 2021, 10:59pm UTC](https://discuss.elastic.co/t/query-prefix-numbers-and-dates/288044/1 "2021-10-29T22:59:00Z")

</div>

So hey i am working with customer where we use flowable which has query models where we can write ES Querys.

In our case we need to search for all elemets in array which have the numberValue idk lets say 222.  
However is it possible with queries that it would be enough to only use 2 as a parameter to get the result with the 222 in it. Kind of like your prefix just for numbers. And the same counts for Dates. We are right now not allowed to use mapping which would make it possible i know....

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [November 1, 2021, 4:27am UTC](https://discuss.elastic.co/t/query-prefix-numbers-and-dates/288044/2 "2021-11-01T04:27:09Z")

</div>

Welcome to our community! 😃

> [@elipongr](#):
>
> However is it possible with queries that it would be enough to only use 2 as a parameter to get the result with the 222 in it

Yes, but you'd get anything else with a 2 at the start (presuming you use wildcards).

> [@elipongr](#):
>
> We are right now not allowed to use mapping which would make it possible i know....

Why not?

---

<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 29, 2021, 4:27am UTC](https://discuss.elastic.co/t/query-prefix-numbers-and-dates/288044/3 "2021-11-29T04:27:35Z")

</div>

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