# More like this on numbers

**URL:** <https://discuss.elastic.co/t/more-like-this-on-numbers/16647>\
**Category:** Elasticsearch\
**Created:** [March 27, 2014, 3:31pm UTC](https://discuss.elastic.co/t/more-like-this-on-numbers/16647 "2014-03-27T15:31:58Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Valentin\_Pletzer](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/valentin_pletzer/32/105548_2.png) [@Valentin\_Pletzer](https://discuss.elastic.co/u/Valentin_Pletzer)\
**Post date:** [March 27, 2014, 3:31pm UTC](https://discuss.elastic.co/t/more-like-this-on-numbers/16647/1 "2014-03-27T15:31:58Z")

</div>

Hi,

as far as I understand it the more like this query allows to find documents  
where the same tokens are used. I wonder if there is a possibility to find  
documents where a particular field is compared based on its value (number).

Regards  
Valentin

PS: elasticsearch rocks!

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/62400c38-f664-4f09-8a39-e1bb45b2f894%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/62400c38-f664-4f09-8a39-e1bb45b2f894%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![Alex\_Ksikes1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/alex_ksikes1/32/1534_2.png) [@Alex\_Ksikes1](https://discuss.elastic.co/u/Alex_Ksikes1)\
**Post date:** [May 6, 2014, 10:04am UTC](https://discuss.elastic.co/t/more-like-this-on-numbers/16647/2 "2014-05-06T10:04:53Z")

</div>

Hi Valentin,

As you know, you can only perform mlt on fields which are analyzed.  
However, you can convert your other fields (number, ..) to text using a  
multi field with type string at indexing time.

Cheers,

Alex

On Thursday, March 27, 2014 4:31:58 PM UTC+1, Valentin wrote:

> Hi,
> 
> as far as I understand it the more like this query allows to find  
> documents where the same tokens are used. I wonder if there is a  
> possibility to find documents where a particular field is compared based on  
> its value (number).
> 
> Regards  
> Valentin
> 
> PS: elasticsearch rocks!

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/d9666a82-cc51-4890-a45f-d695f0600b5a%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/d9666a82-cc51-4890-a45f-d695f0600b5a%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![Valentin\_Pletzer](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/valentin_pletzer/32/105548_2.png) [@Valentin\_Pletzer](https://discuss.elastic.co/u/Valentin_Pletzer)\
**Post date:** [May 7, 2014, 2:14pm UTC](https://discuss.elastic.co/t/more-like-this-on-numbers/16647/3 "2014-05-07T14:14:42Z")

</div>

Hi Alex,

thanks. Good idea to convert the numbers into strings. But converting the  
number fields to string won't exactly solve my problem. Only if there would  
be an analyzer which breaks down numbers into multiple tokens. Eg 300 into  
"100", "200", "300"

Cheers,  
Valentin

On Tuesday, May 6, 2014 12:04:53 PM UTC+2, Alex Ksikes wrote:

> Hi Valentin,
> 
> As you know, you can only perform mlt on fields which are analyzed.  
> However, you can convert your other fields (number, ..) to text using a  
> multi field with type string at indexing time.
> 
> Cheers,
> 
> Alex
> 
> On Thursday, March 27, 2014 4:31:58 PM UTC+1, Valentin wrote:
> 
> > Hi,
> > 
> > as far as I understand it the more like this query allows to find  
> > documents where the same tokens are used. I wonder if there is a  
> > possibility to find documents where a particular field is compared based on  
> > its value (number).
> > 
> > Regards  
> > Valentin
> > 
> > PS: elasticsearch rocks!

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/195f8fa2-821f-4556-b9ae-8924b35c859f%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/195f8fa2-821f-4556-b9ae-8924b35c859f%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![Alex\_Ksikes1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/alex_ksikes1/32/1534_2.png) [@Alex\_Ksikes1](https://discuss.elastic.co/u/Alex_Ksikes1)\
**Post date:** [May 8, 2014, 8:44am UTC](https://discuss.elastic.co/t/more-like-this-on-numbers/16647/4 "2014-05-08T08:44:40Z")

</div>

Hi Valentin,

For these types of searches, have you looked into range queries, perhaps  
combined in a boolean query?

Alex  
On May 7, 2014 4:14 PM, "Valentin" [pletzer@gmail.com](mailto:pletzer@gmail.com) wrote:

> Hi Alex,
> 
> thanks. Good idea to convert the numbers into strings. But converting the  
> number fields to string won't exactly solve my problem. Only if there would  
> be an analyzer which breaks down numbers into multiple tokens. Eg 300 into  
> "100", "200", "300"
> 
> Cheers,  
> Valentin
> 
> On Tuesday, May 6, 2014 12:04:53 PM UTC+2, Alex Ksikes wrote:
> 
> > Hi Valentin,
> > 
> > As you know, you can only perform mlt on fields which are analyzed.  
> > However, you can convert your other fields (number, ..) to text using a  
> > multi field with type string at indexing time.
> > 
> > Cheers,
> > 
> > Alex
> > 
> > On Thursday, March 27, 2014 4:31:58 PM UTC+1, Valentin wrote:
> > 
> > > Hi,
> > > 
> > > as far as I understand it the more like this query allows to find  
> > > documents where the same tokens are used. I wonder if there is a  
> > > possibility to find documents where a particular field is compared based on  
> > > its value (number).
> > > 
> > > Regards  
> > > Valentin
> > > 
> > > PS: elasticsearch rocks!
> > 
> > --  
> > You received this message because you are subscribed to a topic in the  
> > Google Groups "elasticsearch" group.  
> > To unsubscribe from this topic, visit  
> > [https://groups.google.com/d/topic/elasticsearch/Wsye6JD\_\_ys/unsubscribe](https://groups.google.com/d/topic/elasticsearch/Wsye6JD__ys/unsubscribe).  
> > To unsubscribe from this group and all its topics, send an email to  
> > [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > To view this discussion on the web visit  
> > [https://groups.google.com/d/msgid/elasticsearch/195f8fa2-821f-4556-b9ae-8924b35c859f%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/195f8fa2-821f-4556-b9ae-8924b35c859f%40googlegroups.com)[https://groups.google.com/d/msgid/elasticsearch/195f8fa2-821f-4556-b9ae-8924b35c859f%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/195f8fa2-821f-4556-b9ae-8924b35c859f%40googlegroups.com?utm_medium=email&utm_source=footer)  
> > .  
> > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAMrXmPdWStJjTaW5%3D27MrMNLHPkK1hihgrs%3DDs-SAiHzHz9eAQ%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAMrXmPdWStJjTaW5%3D27MrMNLHPkK1hihgrs%3DDs-SAiHzHz9eAQ%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<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:** [July 6, 2017, 1:30am UTC](https://discuss.elastic.co/t/more-like-this-on-numbers/16647/5 "2017-07-06T01:30:53Z")

</div>


