You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by lee carroll <le...@googlemail.com> on 2011/06/17 11:46:34 UTC

difficult sort

Is this possible in 1.4.1

Return a result set sorted by a field but within Categorical groups,
limited to 1 record per group
Something like:
group1
xxx (bottom of sorted field within group)
group2
xxx (bottom of sorted field within group)
etc

is the only approach to issue multiple queries and collate in the
front end app ?

cheers lee c

Re: difficult sort

Posted by pravesh <su...@yahoo.com>.
Yes. Then I beleive you would need multiple queries

--
View this message in context: http://lucene.472066.n3.nabble.com/difficult-sort-tp3075563p3075802.html
Sent from the Solr - User mailing list archive at Nabble.com.

Re: difficult sort

Posted by lee carroll <le...@googlemail.com>.
Thanks for the reply Pravesh

We can't go to trunk or apply patch to production so the field
collapsing goodness is out of reach for now.

Is multiple queries the only way to go for this ?

On 17 June 2011 11:23, pravesh <su...@yahoo.com> wrote:
> I'm not sure, but have looked at Collapsing feature in SOLR yet? You may have
> to apply patch for 1.4.1 version, if this is what u want?
>
>
> --
> View this message in context: http://lucene.472066.n3.nabble.com/difficult-sort-tp3075563p3075661.html
> Sent from the Solr - User mailing list archive at Nabble.com.
>

Re: difficult sort

Posted by pravesh <su...@yahoo.com>.
I'm not sure, but have looked at Collapsing feature in SOLR yet? You may have
to apply patch for 1.4.1 version, if this is what u want?


--
View this message in context: http://lucene.472066.n3.nabble.com/difficult-sort-tp3075563p3075661.html
Sent from the Solr - User mailing list archive at Nabble.com.

RE: difficult sort

Posted by Bob Sandiford <bo...@sirsidynix.com>.
What if you were to set up a new field, which is the concatenation of your 'field' and 'category group', and then facet on that?  How many combinations would we be talking about here?  And - against what field(s) do you run your query?

We did something a bit similar, where we wanted an 'author' search, where 'author' is a field in our documents.  We have a field set up based on 'author' to search against, as well as a field based on 'author' for faceting.  We search against the author field, return 0 results but all the facet values, and then display the facet values with their counts, and when the users select one, then we issue a new query to return all documents with that author facet value.

Bob Sandiford | Lead Software Engineer | SirsiDynix
P: 800.288.8020 X6943 | Bob.Sandiford@sirsidynix.com
www.sirsidynix.com


> -----Original Message-----
> From: lee carroll [mailto:lee.a.carroll@googlemail.com]
> Sent: Friday, June 17, 2011 5:47 AM
> To: solr-user@lucene.apache.org
> Subject: difficult sort
> 
> Is this possible in 1.4.1
> 
> Return a result set sorted by a field but within Categorical groups,
> limited to 1 record per group
> Something like:
> group1
> xxx (bottom of sorted field within group)
> group2
> xxx (bottom of sorted field within group)
> etc
> 
> is the only approach to issue multiple queries and collate in the
> front end app ?
> 
> cheers lee c