# Different core types in single multi\_field

**URL:** <https://discuss.elastic.co/t/different-core-types-in-single-multi-field/14880>\
**Category:** Elasticsearch\
**Created:** [December 16, 2013, 6:41am UTC](https://discuss.elastic.co/t/different-core-types-in-single-multi-field/14880 "2013-12-16T06:41:44Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Preeti\_Jain](https://avatars.discourse-cdn.com/v4/letter/p/67e7ee/32.png) [@Preeti\_Jain](https://discuss.elastic.co/u/Preeti_Jain)\
**Post date:** [December 16, 2013, 6:41am UTC](https://discuss.elastic.co/t/different-core-types-in-single-multi-field/14880/1 "2013-12-16T06:41:44Z")

</div>

Hi,

Can I have different(String, integer, etc) core types in a single  
multi\_field?  
If not, then how to create a custom "\_all" field that conatins values  
from selected fields in the document?

Regards,  
Preeti

--  
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/3121ae92-5924-479d-92d8-d395c0856221%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/3121ae92-5924-479d-92d8-d395c0856221%40googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![spinscale](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/spinscale/32/25011_2.png) [@spinscale](https://discuss.elastic.co/u/spinscale)\
**Post date:** [December 16, 2013, 8:19am UTC](https://discuss.elastic.co/t/different-core-types-in-single-multi-field/14880/2 "2013-12-16T08:19:01Z")

</div>

Hey,

usually you are using a multi field to have different behaviour for  
strings, using it for an int and a double does not make a lot of sense,  
maybe you can tell a bit more about your use-case.

Regarding a custom \_all field: You can configure for every field, if it  
should be put in the all field or not, see the include\_in\_all option in the  
mapping. See

> **[Elasticsearch Platform — Find real-time answers at scale](https://www.elastic.co)**
>
> Power insights and outcomes with the Elasticsearch Platform and AI. See into your data and find answers that matter with enterprise solutions designed to help you build, observe, and protect. Try Elasticsearch free today.

--Alex

On Mon, Dec 16, 2013 at 7:41 AM, Preeti Jain [itspreeti@gmail.com](mailto:itspreeti@gmail.com) wrote:

> Hi,
> 
> Can I have different(String, integer, etc) core types in a single  
> multi\_field?  
> If not, then how to create a custom "\_all" field that conatins values  
> from selected fields in the document?
> 
> Regards,  
> Preeti
> 
> --  
> 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/3121ae92-5924-479d-92d8-d395c0856221%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/3121ae92-5924-479d-92d8-d395c0856221%40googlegroups.com)  
> .  
> For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

--  
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/CAGCwEM-VfVpKbSvnehhBmzjjeME7bG4NBK2sKNCyiSiFSZRRkw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAGCwEM-VfVpKbSvnehhBmzjjeME7bG4NBK2sKNCyiSiFSZRRkw%40mail.gmail.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![nik9000](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nik9000/32/44947_2.png) [@nik9000](https://discuss.elastic.co/u/nik9000)\
**Post date:** [December 16, 2013, 2:00pm UTC](https://discuss.elastic.co/t/different-core-types-in-single-multi-field/14880/3 "2013-12-16T14:00:58Z")

</div>

On Mon, Dec 16, 2013 at 1:41 AM, Preeti Jain [itspreeti@gmail.com](mailto:itspreeti@gmail.com) wrote:

> Hi,
> 
> Can I have different(String, integer, etc) core types in a single  
> multi\_field?  
> If not, then how to create a custom "\_all" field that conatins values  
> from selected fields in the document?

Sure you can. See

> **[Elasticsearch Platform — Find real-time answers at scale](https://www.elastic.co)**
>
> Power insights and outcomes with the Elasticsearch Platform and AI. See into your data and find answers that matter with enterprise solutions designed to help you build, observe, and protect. Try Elasticsearch free today.

an example.

Nik

--  
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/CAPmjWd2AGF7R%3DMXnjLVgQPZTXtk6guF56EQDki5\_WvFkQnxdiA%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAPmjWd2AGF7R%3DMXnjLVgQPZTXtk6guF56EQDki5_WvFkQnxdiA%40mail.gmail.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<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, 2:00am UTC](https://discuss.elastic.co/t/different-core-types-in-single-multi-field/14880/4 "2017-07-06T02:00:57Z")

</div>

Closed on July 6, 2017, 2:00am UTC


