Preference in index mapping


(Faiz Halde) #1

If I'm leveraging dynamic template and let's say I have specified a field say abcd to be of type long and in the dynamic template i specify for any field pattern matching ab*, the type should be string, what will ES infer the type as?


(Mark Walkom) #2

More precise definitions will take precedence over things like (wide) wildcards.

So "abcd": long takes precedence over "abc"*: long.
"abc*": long takes precedence over "ab*": long.