Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-9499

Streaming Expression Cannot sort on aliased field

Attach filesAttach ScreenshotAdd voteVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 6.2
    • None
    • search
    • None
    • 6.2.0_RC1

    Description

      an expression such as:

      search(test, rows=999999, q=table:article_p, fl="yi_pw,id,article:article_id", sort="article asc") 
      
      or
      
      search(test, rows=999999, q=table:article_p, fl="yi_pw,id,article:article_id", sort="article_id asc") 
      

      results in:

      {"result-set":{"docs":[
      {"EXCEPTION":"Fields in the sort spec must be included in the field list:article","EOF":true}]}}
      
      or
      
      {"result-set":{"docs":[
      {"EXCEPTION":"Fields in the sort spec must be included in the field list:article_id","EOF":true}]}}
      

      and

      {"result-set":{"docs":[
      {"EXCEPTION":"Fields in the sort spec must be included in the field list:article:article_id","EOF":true}]}}
      

      yeilds

      {"result-set":{"docs":[
      {"EXCEPTION":"java.util.concurrent.ExecutionException: java.io.IOException: --> http://10.1.3.9:8983/solr/test_shard1_replica1/:sort param could not be parsed as a query, and is not a field that exists in the index: article:article_id","EOF":true,"RESPONSE_TIME":5}]}}
      

      If I sort by id instead, it all works fine.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            Unassigned Unassigned
            gus Gus Heck

            Dates

              Created:
              Updated:

              Slack

                Issue deployment