Solr - How do I construct a query that requires a NOT NULL Location field
问题 I have a Solr index with a set of coordinates stored as a Location type; I would like to query for documents where this field has a non-null value. What is the query syntax to perform the NOT NULL check on a Location field? 回答1: The canonical way is this: fieldName:[* TO *] Using a '' on the left side as Paige Cook suggested will probably work too but I don't trust it as much as I do the above. And since this is to a Location field, you will probably have to do this against one of the two