You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The query pos(inst:GSFC, 1) throws the following exception
Illegal state: combining multiple fields is not allowed: Message with key:Illegal state: combining multiple fields is not allowed and locale: en_US not found.
The text was updated successfully, but these errors were encountered:
The problem here is the use of the inst search field rather than the institution field. The query pos(institution:GSFC, 1) returns the expected results successfully.
The direct issue is that the pos operator attempts to extract a single field from its first argument.
This operator uses the org.apache.lucene.queryparser.flexible.aqp.builders.AqpAdsabsSubQueryProvider#getField method which fails on boolean queries (i.e. queries with multiple clauses joined with boolean operators) with more than one unique field.
The inst field is defined as a "virtual" field; it is used to simultaneously search both the aff_id and institution fields. Internally, these virtual fields seem to get processed into boolean OR-clauses. Since inst has multiple fields, pos throws a syntax error when it is used as the first argument.
The documentation on positional field searches mentions that pos only allows the first argument to use the author, aff, and title fields (which is not complete since institution works as well). However, this page should probably explicitly mention that virtual fields are not allowed. Additionally, the error message reported by ADS could be improved.
If desired, the pos operator could be modified to work with boolean clauses by applying the pos operator to each clause and then joining those queries with the appropriate boolean operators. For example, pos(inst:X, n) could then be transformed into pos(institution:X) OR pos(aff_id:X).
The query
pos(inst:GSFC, 1)
throws the following exceptionThe text was updated successfully, but these errors were encountered: