The following query works well for me
http://...:8983/solr/vault/select?q=White&defType=edismax&qf=VersionComments+VersionName
returns all the documents where version comments includes White
I try to omit the qf containing the fields names : In solr config I write
<requestHandler name="/select" class="solr.SearchHandler">
<!-- default values for query parameters can be specified, these
will be overridden by parameters in the request
-->
<lst name="defaults">
<str name="echoParams">explicit</str>
<int name="rows">10</int>
<str name="df">PackageName</str>
<str name="df">Tag</str>
<str name="df">VersionComments</str>
<str name="df">VersionTag</str>
<str name="df">VersionName</str>
<str name="df">SKU</str>
<str name="df">SKUDesc</str>
</lst>
I restart the solr and create a full import.
Then I try using
http://...:8983/solr/vault/select?q=White&defType=edismax
But I dont get the document any as answer.
What am I doing wrong?
You can use qf (query field) with weight indication.
df
is the default field and will only take effect if theqf
is not defined and its a single definition field in the configuration.You can check the below configuration with qt=edismax parameter :-
Solr 4.8.1 We can make default as follows. by editing solrconfig.xml