Hi, I'm not sure what you mean with how to index a group. You basically index all documents, and then group them for the results. To stay on the books example: you index books including information about the author. So each document in the index is a book. But in your result list, you want to display authors. So you group by author.
For the details about how to group, the package documentation ( http://lucene.apache.org/core/4_0_0-ALPHA/grouping/index.html) should cover what you need. Best, Elisabeth On 27 May 2013 14:13, raj <rajeshmohan.1...@gmail.com> wrote: > Hi, > > I wasnt able to find any guidelines on how to add a Group while indexing. > There is a user guide and demo code for Facet which shows this. Can you > please show how to add a Group while indexing? > > Thanks, > Rajesh > > > On Mon, May 27, 2013 at 3:55 PM, raj <rajeshmohan.1...@gmail.com> wrote: > > > Hi Elisabeth, > > > > Thanks. Let me go through the links > > > > Regards, > > Rajesh > > > > > > On Mon, May 27, 2013 at 3:09 PM, Elisabeth Adler < > > elisabeth.ad...@gmail.com> wrote: > > > >> Hi Rajesh, > >> This entry explains it quite well: > >> > >> > http://stackoverflow.com/questions/8550818/whats-the-difference-between-grouping-and-facet-in-lucene-3-5 > >> Best, > >> Elisabeth > >> > >> On 27 May 2013 11:16, raj <rajeshmohan.1...@gmail.com> wrote: > >> > >> > Hi, > >> > > >> > I was seeing that Lucene supports both Groups and Facets. But I was > >> finding > >> > it difficult to understand the difference between both. > >> > > >> > https://issues.apache.org/jira/browse/LUCENE-1421 - Says "Ability to > >> Group > >> > search results by Field". So, is this by existing Fields that we add > >> while > >> > indexing or something different as in FacetFields in Facets? > >> > > >> > > >> > Regards, > >> > Rajesh > >> > > >> > > > > >