Take the simplest case of indexing the following document in elasticsearch
{ "name": "Mark", "age": 28 } With automatic mapping the mapping for this index would now look like
"properties" : { "doc" : { "properties" : { "age" : { "type" : "long"}, "name" : { "type" : "string" } } }, But say I then wanted to allow the case where this document should be indexed
{ "name": "Bill", "age": "seven" } If I try this the mapping does not update and elasticsearch throws an error since there is a conflict with the type of the age property. Is there any way to do this so both docs could be automatically indexed and consequently queryable?