[ 
https://issues.apache.org/jira/browse/SOLR-10909?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16052872#comment-16052872
 ] 

Erick Erickson commented on SOLR-10909:
---------------------------------------

Please raise issues like this on the user's list _first_. If it's determined 
that it's actually a code issue, _then_ raise a JIRA.

> Cannot sort by function 
> ------------------------
>
>                 Key: SOLR-10909
>                 URL: https://issues.apache.org/jira/browse/SOLR-10909
>             Project: Solr
>          Issue Type: Bug
>      Security Level: Public(Default Security Level. Issues are Public) 
>          Components: Server
>    Affects Versions: 6.4.1
>         Environment: ubuntu 14.4
>            Reporter: David Liu
>
> I have two fields in my solr schema: *solr_weight* and *brand*, I want to 
> implement one query which can dynamically put all brand=XX data in first, and 
> then show others and sort by solr_weight,
> so, I use *if* and *sum* function in solr sort to do it, however, looks like 
> a bug because *if* doesn't work in sort
> {quote}sort=if(brand=="3701"; sum(solr_weight,250000); solr_weight ) 
> desc{quote}
> {quote}ERROR: "msg":"Can't determine a Sort Order (asc or desc) in sort spec 
> 'if(brand==\"3701\"; sum(solr_weight,250000); solr_weight ;) desc', 
> pos=19",{quote}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to