Reputation: 228
We need to set spatial fields like pt, field, and d programmatically. we are using solr library 7.1.0. Looking at the SolrQuery class methods it seems it doesn't have any support to enable spatial query and add spatial parameters. Here is the parameter list which I want to set in my query. Any idea how I can achieve this?
Upvotes: 0
Views: 28
Reputation: 52902
You should be able to use solrQuery.set("fieldname", "value")
to supply custom parameters:
solrQuery.set("pt", "-34...");
solrQuery.set("sfield", "location");
These can also usually be given in your query if you're using {!geofilt
or similar: {!geofilt sfield=location}
.
Upvotes: 1