How to sort over all documents by score after Result Grouping / Field Collapsing

2013-09-23 Thread go2jun
Hi, I have solr documents like this:

 
 
 

I know I can use solr Result Grouping / Field Collapsing to get the top 2
result by grouping by source_id. Within each groups, documents sorted by
scroe by query like this:
http://localhost:8983/solr/select?q=bank&group.field=source_id&group=true&group.limit=2&group.main=true&sort=score

My question is:

1. Is it possible to sort overall documents after I do above grouping?
2. Is there any other ways to implement above functions(by using solr
functions directly)?
3. Is it possible to implement this by writing java code something like
customized request handler to do this?

Thanks in advance,

Jun 





--
View this message in context: 
http://lucene.472066.n3.nabble.com/How-to-sort-over-all-documents-by-score-after-Result-Grouping-Field-Collapsing-tp4091593.html
Sent from the Solr - User mailing list archive at Nabble.com.


Re: How to sort over all documents by score after Result Grouping / Field Collapsing

2013-09-24 Thread go2jun
Thanks Erick for your response.

My goal is
1. try to search from solr. In the search result, we would like show no more
than two results from the same source id.
2. For the search results, we would like all these results sorted by their
score.

So If I use solr result grouping to get the top two result from each group,
then I need to un-group them.

So my question is there any pure solr solution to handle this? I prefer it
handle by solr other than my application, because the search result are very
large.

Thanks!
Jun




--
View this message in context: 
http://lucene.472066.n3.nabble.com/How-to-sort-over-all-documents-by-score-after-Result-Grouping-Field-Collapsing-tp4091593p4091784.html
Sent from the Solr - User mailing list archive at Nabble.com.