I see in Solr 4 the defaultSearchField tag in schema.xml has been deprecated.
I was looking in the Solrj API and I don't see a method for setting the
default field on a SolrQuery object.
This is basically what the code looks like now (stripped down):
solrQuery = SolrQuery.new()
solrQuery.setQuery(queryText)
queryResponse = solrServer.query(solrQuery)
Before Solr 4 this would work fine because defaultSearchField was set in
schema.xml. Now I need to be able to set it from my solrj call.
Am I missing something, how can I set this for my queries via solrj?
As I'm typing this I realize I can do something like I have below (and this
is fine) but still wondering if there is a dedicated method for setting this
somewhere:
solrQuery.add("df", "SearchText")
--
View this message in context:
http://lucene.472066.n3.nabble.com/Setting-df-default-field-from-solrj-tp3999794.html
Sent from the Solr - User mailing list archive at Nabble.com.