I have noticed that the highlighted term of a query are returned in a second xml struct(named "highlighting"). Is it possible to return the highlighted terms into the doc field. I don't need the solr generated ids of the highlighted field.
1 Answers
0
votes
Sorry, Solr does not support returning the highlighted terms into the original doc field.
Solr does highlighting this way since there is the possibility (based on how your highlighter is configured) that there may not be any highlighting results for all query results. Also, since it supports highlighting of multiple fields and uses the second xml struct for returning the possible multiple highlighting results and groups them by the id field of the indexed doc so they can correctly correlated to the document for which they were found.
You will need to perform your own processing after the Solr query results have been returned if you want to replace the original document field with the highlighted field to display.