Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I see/debug the way SOLR find it's results?

Let's say I search for "ABLS" and the SOLR returns a result that to me does not make any sense.
How can I debug why SOLR picked this record to be returned?

like image 538
Itay Moav -Malimovka Avatar asked Feb 23 '12 23:02

Itay Moav -Malimovka


People also ask

How do I debug Solr query?

You could add debugQuery=true&indent=true to the url and examine the results. You could also use the analysis tool in solr. Go to the admin and click analysis. You would need to read the wiki to understand either of these more in depth.

What is the default return type of Solr request?

The default value is 0 . In other words, by default, Solr returns results without an offset, beginning where the results themselves begin.

How query all fields in Solr?

The correct way is the copyField you have and declaring the field all as the default search field. That's how the examples that ship with Solr out of the box do it. Excellent, adding <str name="df">all</str> to defaults in solrconfig. xml indeed solved this.

How do I run a query in Solr?

You can search for "solr" by loading the Admin UI Query tab, enter "solr" in the q param (replacing *:* , which matches all documents), and "Execute Query". See the Searching section below for more information. To index your own data, re-run the directory indexing command pointed to your own directory of documents.


2 Answers

debugQuery=true would help you get the detailed score calculation and the explanation for each scores.

An over view of the scoring is available at link

For detailed explaination of the debug information you can refer Link

like image 199
Jayendra Avatar answered Oct 25 '22 15:10

Jayendra


You could add debugQuery=true&indent=true to the url and examine the results. You could also use the analysis tool in solr. Go to the admin and click analysis. You would need to read the wiki to understand either of these more in depth.

like image 32
d whelan Avatar answered Oct 25 '22 14:10

d whelan