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 Phill Tornroth <fa...@gmail.com> on 2012/04/27 01:07:26 UTC
Per-User Sorting on an ExternalFileField
I'm trying pretty hard to come up with a solution that lets me sort by
per-user scores that I calculate based on my data. Today, I'm trying to use
a combination of ExternalFileField and dynamic fields, where the
presumption is that each user might have their own file full of scores. I
think the fields are hooked up okay, but I can't sort on them because it
appears ExternalFileField explicitly doesn't support this operation.
SEVERE: java.lang.UnsupportedOperationException
at
org.apache.solr.schema.ExternalFileField.getSortField(ExternalFileField.java:91)
I'm using Solr 3.5. Does anyone have a suggestion as to how to end up
adding this extra dimension so that I can do per-user relevance? It seems
like an oft-asked, rarely-answered question.
Thanks in advance,
Phill
Re: Per-User Sorting on an ExternalFileField
Posted by Phill Tornroth <fa...@gmail.com>.
So, I did just issue:
&sort=sub(my_user_score_field,0)+desc
It got me past the error, but still doesn't appear to be actually using the
values to sort. Any ideas as to why?
Phill
On Thu, Apr 26, 2012 at 4:35 PM, Stephane Bailliez <sb...@gmail.com>wrote:
> On Fri, Apr 27, 2012 at 12:07 AM, Phill Tornroth <famousactress@gmail.com
> >wrote:
>
> > I'm using Solr 3.5. Does anyone have a suggestion as to how to end up
> > adding this extra dimension so that I can do per-user relevance? It seems
> > like an oft-asked, rarely-answered question.
> >
>
> Use a function that make use of your externalfilefield and alter the score
> so that you can sort on the score ?
>
Re: Per-User Sorting on an ExternalFileField
Posted by Stephane Bailliez <sb...@gmail.com>.
On Fri, Apr 27, 2012 at 12:07 AM, Phill Tornroth <fa...@gmail.com>wrote:
> I'm using Solr 3.5. Does anyone have a suggestion as to how to end up
> adding this extra dimension so that I can do per-user relevance? It seems
> like an oft-asked, rarely-answered question.
>
Use a function that make use of your externalfilefield and alter the score
so that you can sort on the score ?