Reputation: 192
Using copyfield I copyed all the document fields in one field, after quering the result I want to show the search result in Paragraph format :
For example, I have some indexed data about solr in some documents and if i query for
/solr?q=copyAllFields:solr
Result should be populate as:
DOC-110
Solr is an open-source search server based on the Lucene Java search library. News, documentation, resources, and download... Solr is a standalone enterprise search server with a REST-like API. You put ...DOC-898
Solr(pronounced "solar") is an open source enterprise search platform from the Apache... Its major features include full-text search, hit highlighting ...
Upvotes: 0
Views: 1125
Reputation: 9500
Use Solr's highlighting component for this task. This will get you an additional section in Solr's search result that contains text paragraphs the way you want it. The word that produced the hit will be surrounded within a configurable tags.
How this component can be used is rather good documented in the following sources
Upvotes: 3