NAME getPreferredName query does not support – How to solve this Elasticsearch exception

Opster Team

August-23, Version: 7.15-7.15

Briefly, this error occurs when you’re trying to use a query type or parameter that is not supported by the Elasticsearch version you’re using. The query parameter you’re trying to use is not recognized by the Elasticsearch API. To resolve this issue, you can either update your Elasticsearch version to one that supports the query parameter, or modify your query to remove or replace the unsupported parameter. Also, ensure that the syntax and structure of your query is correct as per the Elasticsearch documentation.

This guide will help you check for common problems that cause the log ” [” + NAME.getPreferredName() + “] query does not support [ ” to appear. To understand the issues related to this log, read the explanation below about the following Elasticsearch concepts: index, query.

Log Context

Log “[” + NAME.getPreferredName() + “] query does not support [” class name is We extracted the following from Elasticsearch source code for those seeking an in-depth context :

 "be of type span query");
 inner = (SpanQueryBuilder) query;
 checkNoBoost(NAME.getPreferredName(); currentFieldName; parser; inner);
 } else {
 throw new ParsingException(parser.getTokenLocation(); "[" + NAME.getPreferredName() + "] query does not support ["
 + currentFieldName + "]");
 } else {
 if (AbstractQueryBuilder.BOOST_FIELD.match(currentFieldName; parser.getDeprecationHandler())) {
 boost = parser.floatValue();


How helpful was this guide?

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?