elasticsearch/elasticsearch — Issue #1558: Allow search to continue when sort field is missing from type mapping
Author: bryangreen
Created: 2011-12-21 23:02:45+00:00
State: open

I'd like the search to ignore the sort key when it is missing from a type's mapping.

This could be an option for the sort key such as "ignore_missing": true

For instance,
{
"from": 0,
"size": "15",
"sort": {
"title": {
"order": "asc",
"ignore_missing": true
}
}
}

I have this error throwing on some indexes and sometimes throws the search. This would be a great feature!

I'm open to other implementations as well. For instance, this could be a setting you save on the default mapping or each type's mapping.